Subject: Re: [Boost-bugs] [Boost C++ Libraries] #5789: Segmentation fault with serialization when register_type rearranged
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2012-07-15 20:49:28
#5789: Segmentation fault with serialization when register_type rearranged
---------------------------------------------------+------------------------
Reporter: Krzysztof Tomaszewski <kt@â¦> | Owner: ramey
Type: Bugs | Status: closed
Milestone: To Be Determined | Component: serialization
Version: Boost 1.47.0 | Severity: Problem
Resolution: invalid | Keywords:
---------------------------------------------------+------------------------
Changes (by ramey):
* status: new => closed
* resolution: => invalid
Comment:
If I understand your problem correctly
"1) our program serializes some data with boost-serialization 2) we add
new class registration, so function RegisterDerivedClasses? changes to
something like this: --- template <class Archive> void
RegisterDerivedClasses?(Archive& ar) {"
I think the answer is the following:
a) using the "registration method" adds data to the archive.
b) adding another "registration method" adds more data to the archive.
c) problem occurs when reading previously saved data with new program.
and the solution is:
a) remember that using the "registration method" is really no different
then adding any kind of new data to the archive definition.
b) adding any new data required using class versioning to keep things in
sync.
c) If you implement class versioning - I believe this will address this
problem.
I think I'm correct on this, so I'm going to close this item for now.
Robert Ramey
Robert Ramey
-- Ticket URL: <https://svn.boost.org/trac/boost/ticket/5789#comment:4> Boost C++ Libraries <http://www.boost.org/> Boost provides free peer-reviewed portable C++ source libraries.
This archive was generated by hypermail 2.1.7 : 2017-02-16 18:50:10 UTC