Boost logo

Boost Users :

Subject: [Boost-users] [Serialization] creating an archive fails under GCC-4.6.0
From: doug livesey (biot023_at_[hidden])
Date: 2011-04-16 12:49:16


Hi -- I have some code that runs when compiled with GCC-4.2 (on OSX Snow
Leopard), but that throws the following error with my fresh compile of
4.6.0:
   run_features(2872) malloc: *** error for object 0x100502060: pointer
being freed was not allocated
   *** set a breakpoint in malloc_error_break to debug

The line that creates this error is here, on line 24:
https://gist.github.com/923262
(Apologies for any egregious code abuses in there, I'm just learning!)
In the debugger, it lets me step from that line to the constructor of
xml_oarchive (line 114 of xml_oarchive.hpp), and when I try to step any
further, I get this:
   run_features(2885) malloc: *** error for object 0x100501b00: pointer
being freed was not allocated
   *** set a breakpoint in malloc_error_break to debug

   Program received signal SIGABRT, Aborted.
   0x00007fff871a95d6 in __kill ()

Could anyone advise me on what I could do to fix this? I really want to be
working with GCC 4.6.0 and the boost serialisation libraries.
Incidentally, I reinstalled boost after I installed the latest GCC (with
homebrew), and I'd set cc, gcc, and g++ symlinks to GCC-4.6.0 before I did
that, so boost should be compiled with the latest.
Thanks very much for any & all assistance.
   Doug.



Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net