<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="http://git.reviewboard.kde.org/r/100252/">http://git.reviewboard.kde.org/r/100252/</a>
     </td>
    </tr>
   </table>
   <br />





 <pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">a few small changes then I'm fine with this. Thanks already. Care to give kdevplatform a shot at this next?

Btw: I'll merge this only into master (i.e. what will become 4.3) to give it some testing.</pre>
 <br />





<div>




<table width="100%" border="0" bgcolor="white" style="border: 1px solid #C0C0C0; border-collapse: collapse; margin: 2px padding: 2px;">
 <thead>
  <tr>
   <th colspan="4" bgcolor="#F0F0F0" style="border-bottom: 1px solid #C0C0C0; font-size: 9pt; padding: 4px 8px; text-align: left;">
    <a href="http://git.reviewboard.kde.org/r/100252/diff/2/?file=5722#file5722line852" style="color: black; font-weight: bold; text-decoration: underline;">debuggers/gdb/debugsession.cpp</a>
    <span style="font-weight: normal;">

     (Diff revision 2)

    </span>
   </th>
  </tr>
 </thead>

 <tbody style="background-color: #e4d9cb; padding: 4px 8px; text-align: center;">
  <tr>

   <td colspan="4"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">void DebugSession::parseStreamRecord(const GDBMI::StreamRecord& s)</pre></td>

  </tr>
 </tbody>






 
 

 <tbody>

  <tr>
    <th bgcolor="#f0f0f0" style="border-right: 1px solid #C0C0C0;" align="right"><font size="2">852</font></th>
    <td bgcolor="#ffffff" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span class="n">m_gdb</span> <span class="o">=</span> <span class="k">new</span> <span class="n">GDB</span><span class="p">(</span><span class="k">this</span><span class="p">);</span></pre></td>
    <th bgcolor="#f0f0f0" style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" align="right"><font size="2">852</font></th>
    <td bgcolor="#ffffff" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">    <span class="n">m_gdb</span> <span class="o">=</span> <span class="k">new</span> <span class="n">GDB</span><span class="p">(</span><span class="k">this</span><span class="p">);</span></pre></td>
  </tr>

 </tbody>

</table>

<pre style="margin-left: 2em; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">rewrite this as:

GDB* gdb = new GDB(this);
m_gdb = gdb;

and then use gdb in the connect statements below, I find that nicer than going to .data() route repeatedly</pre>
</div>
<br />

<div>




<table width="100%" border="0" bgcolor="white" style="border: 1px solid #C0C0C0; border-collapse: collapse; margin: 2px padding: 2px;">
 <thead>
  <tr>
   <th colspan="4" bgcolor="#F0F0F0" style="border-bottom: 1px solid #C0C0C0; font-size: 9pt; padding: 4px 8px; text-align: left;">
    <a href="http://git.reviewboard.kde.org/r/100252/diff/2/?file=5722#file5722line862" style="color: black; font-weight: bold; text-decoration: underline;">debuggers/gdb/debugsession.cpp</a>
    <span style="font-weight: normal;">

     (Diff revision 2)

    </span>
   </th>
  </tr>
 </thead>

 <tbody style="background-color: #e4d9cb; padding: 4px 8px; text-align: center;">
  <tr>

   <td colspan="4"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">void DebugSession::parseStreamRecord(const GDBMI::StreamRecord& s)</pre></td>

  </tr>
 </tbody>






 
 

 <tbody>

  <tr>
    <th bgcolor="#f0f0f0" style="border-right: 1px solid #C0C0C0;" align="right"><font size="2">862</font></th>
    <td bgcolor="#ffffff" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "><span class="c">    connect(m_gdb, SIGNAL(applicationOutput(const QString&)),</span></pre></td>
    <th bgcolor="#f0f0f0" style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" align="right"><font size="2">862</font></th>
    <td bgcolor="#ffffff" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "><span class="c">    connect(m_gdb, SIGNAL(applicationOutput(const QString&)),</span></pre></td>
  </tr>

 </tbody>

</table>

<pre style="margin-left: 2em; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">please change it here as well</pre>
</div>
<br />

<div>




<table width="100%" border="0" bgcolor="white" style="border: 1px solid #C0C0C0; border-collapse: collapse; margin: 2px padding: 2px;">
 <thead>
  <tr>
   <th colspan="4" bgcolor="#F0F0F0" style="border-bottom: 1px solid #C0C0C0; font-size: 9pt; padding: 4px 8px; text-align: left;">
    <a href="http://git.reviewboard.kde.org/r/100252/diff/2/?file=5725#file5725line106" style="color: black; font-weight: bold; text-decoration: underline;">debuggers/gdb/gdbvariable.cpp</a>
    <span style="font-weight: normal;">

     (Diff revision 2)

    </span>
   </th>
  </tr>
 </thead>

 <tbody style="background-color: #e4d9cb; padding: 4px 8px; text-align: center;">
  <tr>

   <td colspan="4"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">public:</pre></td>

  </tr>
 </tbody>



 
 




 <tbody>

  <tr>
    <th bgcolor="#e9eaa8" style="border-right: 1px solid #C0C0C0;" align="right"><font size="2">106</font></th>
    <td bgcolor="#fdfebc" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">            <span class="n">m_variable</span><span class="o">-></span><span class="n">deleteChildren</span><span class="p">();</span></pre></td>
    <th bgcolor="#e9eaa8" style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" align="right"><font size="2">106</font></th>
    <td bgcolor="#fdfebc" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">            <span class="n">m_variable</span><span class="p"><span class="hl">.</span></span><span class="n"><span class="hl">data</span></span><span class="p"><span class="hl">()</span></span><span class="o">-></span><span class="n">deleteChildren</span><span class="p">();</span></pre></td>
  </tr>

 </tbody>

</table>

<pre style="margin-left: 2em; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">variable = m_variable.data();

then use it below to make it nicer (imo)</pre>
</div>
<br />

<div>




<table width="100%" border="0" bgcolor="white" style="border: 1px solid #C0C0C0; border-collapse: collapse; margin: 2px padding: 2px;">
 <thead>
  <tr>
   <th colspan="4" bgcolor="#F0F0F0" style="border-bottom: 1px solid #C0C0C0; font-size: 9pt; padding: 4px 8px; text-align: left;">
    <a href="http://git.reviewboard.kde.org/r/100252/diff/2/?file=5730#file5730line40" style="color: black; font-weight: bold; text-decoration: underline;">languages/cpp/codegen/unresolvedincludeassistant.cpp</a>
    <span style="font-weight: normal;">

     (Diff revision 2)

    </span>
   </th>
  </tr>
 </thead>

 <tbody style="background-color: #e4d9cb; padding: 4px 8px; text-align: center;">
  <tr>

   <td colspan="4"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">Cpp::AddCustomIncludePathAction::AddCustomIncludePathAction(KDevelop::IndexedString url, QString directive) {</pre></td>

  </tr>
 </tbody>



 
 




 <tbody>

  <tr>
    <th bgcolor="#e9eaa8" style="border-right: 1px solid #C0C0C0;" align="right"><font size="2">40</font></th>
    <td bgcolor="#fdfebc" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">  <span class="n">QPointer</span><span class="o"><</span><span class="n">KDialog</span><span class="o">></span> <span class="n">dialog</span> <span class="o">=</span> <span class="k">new</span> <span class="n">KDialog</span><span class="p">(</span><span class="n">KDevelop</span><span class="o">::</span><span class="n">ICore</span><span class="o">::</span><span class="n">self</span><span class="p">()</span><span class="o">-></span><span class="n">uiController</span><span class="p">()</span><span class="o">-></span><span class="n">activeMainWindow</span><span class="p">());</span></pre></td>
    <th bgcolor="#e9eaa8" style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" align="right"><font size="2">40</font></th>
    <td bgcolor="#fdfebc" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; ">  <span class="n">Q<span class="hl">Weak</span>Pointer</span><span class="o"><</span><span class="n">KDialog</span><span class="o">></span> <span class="n">dialog</span> <span class="o">=</span> <span class="k">new</span> <span class="n">KDialog</span><span class="p">(</span><span class="n">KDevelop</span><span class="o">::</span><span class="n">ICore</span><span class="o">::</span><span class="n">self</span><span class="p">()</span><span class="o">-></span><span class="n">uiController</span><span class="p">()</span><span class="o">-></span><span class="n">activeMainWindow</span><span class="p">());</span></pre></td>
  </tr>

 </tbody>

</table>

<pre style="margin-left: 2em; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">that should be rewritten to not use a QPointer/QWeakPointer at all

Instead the dialog should be created on stack:

KDialog dialog(....);
...
dialog.exec();
// no delete
}</pre>
</div>
<br />



<p>- Milian</p>


<br />
<p>On December 28th, 2010, 12:22 p.m., NathanaĆ«l Restori wrote:</p>






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

<div>Review request for KDevelop.</div>
<div>By NathanaĆ«l Restori.</div>


<p style="color: grey;"><i>Updated 2010-12-28 12:22:17</i></p>




<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;">The patch convert every QPointer in QWeakPointer
In the bug report, Millan Wolff says : "it shows that in GDB the pointer was used quite a lot without being checked,
you should do that at the start of each function, or at least Q_ASSERT on it." but for hardly every function, there is a "Q_ASSERT(thePointer)", a "if (thePointer)" or a "if (!thePointer)"</pre>
  </td>
 </tr>
</table>


<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Testing </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;">Only try to compile.</pre>
  </td>
 </tr>
</table>



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


 <a href="http://bugs.kde.org/show_bug.cgi?id=260586">260586</a>


</div>


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

 <li>debuggers/gdb/debuggerplugin.h <span style="color: grey">(9144d25)</span></li>

 <li>debuggers/gdb/debugsession.h <span style="color: grey">(4abbc11)</span></li>

 <li>debuggers/gdb/debugsession.cpp <span style="color: grey">(b050db2)</span></li>

 <li>debuggers/gdb/gdbcommand.h <span style="color: grey">(63c4c34)</span></li>

 <li>debuggers/gdb/gdbcommand.cpp <span style="color: grey">(c46f0ec)</span></li>

 <li>debuggers/gdb/gdbvariable.cpp <span style="color: grey">(8e47f6e)</span></li>

 <li>debuggers/gdb/unittests/gdbtest.cpp <span style="color: grey">(41980e9)</span></li>

 <li>languages/cpp/codecompletion/model.h <span style="color: grey">(84c1e1e)</span></li>

 <li>languages/cpp/codegen/codeassistant.h <span style="color: grey">(a5cbeb8)</span></li>

 <li>languages/cpp/codegen/codeassistant.cpp <span style="color: grey">(c9a3673)</span></li>

 <li>languages/cpp/codegen/unresolvedincludeassistant.cpp <span style="color: grey">(9c5872b)</span></li>

</ul>

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




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








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