<br><br><div><span class="gmail_quote">2007/5/29, Albert Astals Cid <<a href="mailto:aacid@kde.org">aacid@kde.org</a>>:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
A Dimarts 29 Maig 2007, Guillaume Denry va escriure:<br>> 2007/5/29, Guillaume Denry <<a href="mailto:guillaume.denry@gmail.com">guillaume.denry@gmail.com</a>>:<br>> > 2007/5/29, Johann Ollivier Lapeyre <
<a href="mailto:johann.ollivierlapeyre@gmail.com">johann.ollivierlapeyre@gmail.com</a>>:<br>> > > Hi,<br>> > ><br>> > > Bovo was very good in playground, and after the dev approval, it was<br>
> > > moved to kdereview, even if the dev had a tmp computer issue.<br>> > ><br>> > > But now, the 1st june limit is coming, the aron's computer is still<br>> > > dead for few days, and the kdereview's bovo is crashing since at least
<br>> > > 1 week. I asked to Guid to look on it, but he didn't found yet.<br>> ><br>> > Crash finally found. \o/<br>> > I'll send the patch in a few minutes for a review, stay tuned.<br>
><br>> Crash was caused by a multi-referencing of the same Coord pointer (m_coord)<br>> in the Move class. (Because of the implicit copy constructor of Move which<br>> copied pointers in the back() or last() function of QList)
<br>> I replaced "Coord *m_coord;" by "Coord m_coord;" and changed some Move<br>> functions consequently, I think it won't cause any troubles now.<br><br>Well, you discovered the failure, but failed to implement the "least lines
<br>change will fix it", that is implementing the copy constructor to behave<br>correctly<br><a href="http://websvn.kde.org/trunk/kdereview/bovo/game/move.cc?r1=669582&r2=669581&pathrev=669582">http://websvn.kde.org/trunk/kdereview/bovo/game/move.cc?r1=669582&r2=669581&pathrev=669582
</a><br><br>I'm not saying that your patch was wrong (in fact i think it would be a good<br>thing to hold the Coord itself and not a pointer to a Coord), just mine is<br>more efficient in lines changed, and given neither me and you are the
<br>mantainer i think is a good thing to change as less as possible.</blockquote><div><br>No problem. <br>Nevertheless, continuing to use pointers without redefine =operator in the Move class could lead to future crashes but I totally agree with this "least lines change will fix it" principle.
<br><br>Guid</div></div><br>