Kai-Uwe Bux wrote:
> wrote:
>
> > It is my understanding that if you contain vectors or maps you don't
> > need to create copy constructors because the default calls that
> > constructor.
>
> You mean: if you *only* contain vectors or maps.
Well, no, there are also primatives.
>
> > It is my understanding that if you use these types you
> > don't have to worry about them at all...even if the contents of your
> > map or vector may contain other maps or vectors. Am I mistaken in any
> > way?
>
> Well, if your maps and vectors contain (by any level of indirection)
> pointers of unknown origin, life gets harder.
>
>
> > We are running into a very strange bug that is avoiding detection by
> > hiding in the default allocator of std::vector. The crash occurs when
> > push_back reaches a point where it actually deletes the current vector
> > after creating the new one. None of the types contained within the
> > vector contain pointers they manage (there are std containers in one of
> > the eventual contents).
>
> Just a wild speculation: maybe you keep an iterator that gets invalidated in
> the reallocation of the vector. That could be an iterator to the vector
> itself or to any container indirectly stored therein.
I don't believe so. Nothing obvious anyway.
>
> Do you have code you could post that shows the problem?
No, program is huge and proprietery and like Daniel said, it could be
anywhere; I really think something out there is hosing a buffer
somewhere and this vector is always in the way...which is odd
but...well I have no idea. I wasn't really expecting to be able to be
helped

Only if I was wrong about the above and I was damn sure I
wasn't but there was some discussion about it.
>
>
> > Luckily this bug also doesn't happen if the program is started in the
> > debugger.
>
> "Luckily"?
Yeah, nice huh...We'll just tell the customers they have to run the
program in the debugger...yeah, that should work
I don't envy my coworker