Boost C++ Libraries: Ticket #1037: boost.serialization : invalid pointer dependant upon serialization order https://svn.boost.org/trac10/ticket/1037 <p> thierry@thierry-laptop:~/$ ./a.out 4=(nil) 3=0x622150 2=0x622150 1=0x622140 0=0x622140 terminate called after throwing an instance of 'boost::archive::archive_exception' </p> <blockquote> <p> what(): pointer conflict </p> </blockquote> <p> Aborted (core dumped) </p> <p> attached file reproduces bug and comment on where change order can make code pass </p> <p> env : ubuntu 7.04, gcc 4.1.1 </p> en-us Boost C++ Libraries /htdocs/site/boost.png https://svn.boost.org/trac10/ticket/1037 Trac 1.4.3 anonymous Wed, 06 Jun 2007 23:32:53 GMT attachment set https://svn.boost.org/trac10/ticket/1037 https://svn.boost.org/trac10/ticket/1037 <ul> <li><strong>attachment</strong> → <span class="trac-field-new">pointerconflict.cpp</span> </li> </ul> Ticket ramey@… Tue, 03 Jul 2007 17:00:11 GMT <link>https://svn.boost.org/trac10/ticket/1037#comment:1 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/1037#comment:1</guid> <description> <p> User error. </p> <p> Described in documentation under "archive exceptions" </p> <p> Robert Ramey </p> </description> <category>Ticket</category> </item> <item> <dc:creator>Eric Niebler</dc:creator> <pubDate>Wed, 11 Jul 2007 02:02:58 GMT</pubDate> <title>owner set https://svn.boost.org/trac10/ticket/1037#comment:2 https://svn.boost.org/trac10/ticket/1037#comment:2 <ul> <li><strong>owner</strong> set to <span class="trac-author">Robert Ramey</span> </li> </ul> Ticket Robert Ramey Wed, 11 Jul 2007 03:37:36 GMT status changed; resolution set https://svn.boost.org/trac10/ticket/1037#comment:3 https://svn.boost.org/trac10/ticket/1037#comment:3 <ul> <li><strong>status</strong> <span class="trac-field-old">new</span> → <span class="trac-field-new">closed</span> </li> <li><strong>resolution</strong> → <span class="trac-field-new">invalid</span> </li> </ul> Ticket tg38@… Fri, 13 Jul 2007 17:22:45 GMT status changed; resolution deleted https://svn.boost.org/trac10/ticket/1037#comment:4 https://svn.boost.org/trac10/ticket/1037#comment:4 <ul> <li><strong>status</strong> <span class="trac-field-old">closed</span> → <span class="trac-field-new">reopened</span> </li> <li><strong>resolution</strong> <span class="trac-field-deleted">invalid</span> </li> </ul> <p> Replying to <a class="ticket" href="https://svn.boost.org/trac10/ticket/1037#comment:3" title="Comment 3">ramey</a>: </p> <p> Just calling for more comments if no fixes. </p> <p> If this is an error, isn't it an error in both implementation, and shall raise exception in both cases? </p> <p> Could you then add to documentation (in tutorial) how to save vectors of scalar type that can be pointed to by other stucture? </p> <p> Still, I wonder why this is considered a "user" bug, because it seems contradictory to the library goals. When it is limitation i would be prefer early emphasis on doc. </p> Ticket Robert Ramey Fri, 13 Jul 2007 19:51:12 GMT status, severity changed; resolution set https://svn.boost.org/trac10/ticket/1037#comment:5 https://svn.boost.org/trac10/ticket/1037#comment:5 <ul> <li><strong>status</strong> <span class="trac-field-old">reopened</span> → <span class="trac-field-new">closed</span> </li> <li><strong>resolution</strong> → <span class="trac-field-new">invalid</span> </li> <li><strong>severity</strong> <span class="trac-field-old">Showstopper</span> → <span class="trac-field-new">Not Applicable</span> </li> </ul> <p> This is explained in the documentation under <a class="missing wiki">Reference/Special</a> <a class="missing wiki">Considerations/Archive</a> Exceptions/pointer conflict. </p> <p> This occurs when an object is first loaded through a pointer, thereby creating a new object, then loading the same object to a specific place. With no exception, we would end up with two objects where we started with one before. There is no obvious way to address this without making the serialization loading multi-pass - which would create a whole host of other issues. </p> <p> Note that questions like this are much better posted on the mailing list rather than filing a "bug report" </p> <p> Robert Ramey </p> Ticket