This is the mail archive of the libstdc++@gcc.gnu.org mailing list for the libstdc++ project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: core dumped when adding to vector


Joe Buck wrote:

I have an enum called protocol_states and a vector<protocol_state> which contains
some elements. When I call the insert method of an other empty vector<protocol_state>
in order to copy the elements of the first vector, a core dumped occurs.



On Fri, Jun 24, 2005 at 04:16:32PM +0100, chris jefferson wrote:


The best place to submit bug reports is to http://gcc.gnu.org/bugzilla/. If you submit it there, someone will come along and tell you if it is a bug in libstdc++ or a bug in your code.



Chris, why are you assuming that there's a bug in GCC or libstdc++? Vectors of enums are trivial and just work for everyone else.

I suspect that there is some other bug in the program, one that corrupts
the heap.  This is particularly likely if the allocator is dumping core.



I would indeed be deeply shocked if there is a bug in vectors of enums. However, if someone has a 5 line example which they believes shows a bug in libstdc++ or gcc, I would have thought that bugzilla would be the right place to post it (I'm happy to be told that that isn't the right place)

Chris


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]