<html>
 <body>
  <div style="font-family: Verdana, Arial, Helvetica, Sans-Serif;">
   <table bgcolor="#f9f3c9" width="100%" cellpadding="8" style="border: 1px #c9c399 solid;">
    <tr>
     <td>
      This is an automatically generated e-mail. To reply, visit:
      <a href="https://git.reviewboard.kde.org/r/116602/">https://git.reviewboard.kde.org/r/116602/</a>
     </td>
    </tr>
   </table>
   <br />





<blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
 <p style="margin-top: 0;">On March 26th, 2014, 12:27 p.m. UTC, <b>Dawit Alemayehu</b> wrote:</p>
 <blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
  <pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Do you want me to apply this patch with the minor changes I suggested?</pre>
 </blockquote>







</blockquote>

<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Sorry for the late reply!

Based on how these metadata are used (ssl_in_use, ssl_was_in_use) if the map contains the key the associated value string could (well... should) only be equals to "TRUE" or "FALSE". So when looking up for the key using queryMetaData() if the map doesn't contain the key a Null string is returned, that's why i used !sslInUse.isNull() (it's the same as checking for map.contains(key)).
About the other changes you suggested i found my code more readable.
However the goal doesn't change so i'm fine if you apply the patch with the changes you suggested.

One last thing i found grepping the code for "ssl_in_use".
In kdelibs/kio/kio/accessmanager.cpp:482 should not the check
if (metadata.contains(QL1S(""ssl_in_use"")))
be changed to
if (metadata.value(QL1S("ssl_in_use")) == QL1S("TRUE"))
for the same reason i stated above?</pre>
<br />










<p>- Andrea</p>


<br />
<p>On March 4th, 2014, 9:43 p.m. UTC, Andrea Iacovitti wrote:</p>








<table bgcolor="#fefadf" width="100%" cellspacing="0" cellpadding="8" style="background-image: url('https://git.reviewboard.kde.org/static/rb/images/review_request_box_top_bg.ab6f3b1072c9.png'); background-position: left top; background-repeat: repeat-x; border: 1px black solid;">
 <tr>
  <td>

<div>Review request for kdelibs and Dawit Alemayehu.</div>
<div>By Andrea Iacovitti.</div>


<p style="color: grey;"><i>Updated March 4, 2014, 9:43 p.m.</i></p>









<div style="margin-top: 1.5em;">
 <b style="color: #575012; font-size: 10pt;">Repository: </b>
kdelibs
</div>


<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Description </h1>
 <table width="100%" bgcolor="#ffffff" cellspacing="0" cellpadding="10" style="border: 1px solid #b8b5a0">
 <tr>
  <td>
   <pre style="margin: 0; padding: 0; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">If incomingMetaData doesn't contain item with key "ssl_in_use" (and i verified this happen) using [] operator results in inserting a new item with key "ssl_in_use" and NullString value in incomingMetaData map and, as a consequence, a new item with key "ssl_was_in_use" and NullString value in outgoingMetaData map.
This patch aims to avoid this situation by looking up the key using queryMetadata().</pre>
  </td>
 </tr>
</table>



<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Diffs</b> </h1>
<ul style="margin-left: 3em; padding-left: 0;">

 <li>kio/kio/job.cpp <span style="color: grey">(edc5fed)</span></li>

</ul>

<p><a href="https://git.reviewboard.kde.org/r/116602/diff/" style="margin-left: 3em;">View Diff</a></p>







  </td>
 </tr>
</table>








  </div>
 </body>
</html>