[boost.serialization] serialization crash
The following code crashes under cygwin+boost1.33 and under mingw+boost1.33
I create text archive in a file, and then serialization crashes when
restoring object from that archive.
The problem seem to be with bool field, if I replace
bool x;
with
int x;
in the class Obj implementation, everything runs fine.
Is this a bug in serialization code?
#include <iostream>
#include <sstream>
#include <fstream>
#include <vector>
#include <map>
using namespace std;
#include
Might be a problem with uninitialized bool value. Look into your
text-archive if the bool value is 0 or 1.
Try initializing your bool member either to true or false and test again.
Regards,
Oliver
-----Ursprüngliche Nachricht-----
Von: boost-users-bounces@lists.boost.org
[mailto:boost-users-bounces@lists.boost.org] Im Auftrag von Pavlo Korzhyk
Gesendet: Donnerstag, 26. Oktober 2006 16:09
An: boost-users@lists.boost.org
Betreff: [Boost-users] [boost.serialization] serialization crash
The following code crashes under cygwin+boost1.33 and under mingw+boost1.33
I create text archive in a file, and then serialization crashes when
restoring object from that archive.
The problem seem to be with bool field, if I replace
bool x;
with
int x;
in the class Obj implementation, everything runs fine.
Is this a bug in serialization code?
#include <iostream>
#include <sstream>
#include <fstream>
#include <vector>
#include <map>
using namespace std;
#include
participants (2)
-
Oliver Mutz
-
Pavlo Korzhyk