shiva@well.sf.ca.us (Kenneth Porter) (12/06/90)
I'm running OS/2 1.2 on a Dell 386/20 and hitting a problem with DosReallocSeg() and multi-threading. If multiple threads try to realloc a segment, DosReallocSeg returns a garbage error code. I first found this while tracing through a _beginthread() that never returned. It was calling DosReallocSeg by way of malloc when it was allocating the new thread's stack. A quick test program which spawns two threads each of which realloc a segment allocated by thread 1 will quickly demonstrate the bug. The garbage error code returned is code-sensitive; ie. small edits change the value returned. Pending the arrival of 1.3, what can I do about this? Has anyone more information about this problem, what strokes it, and how it can be fixed? Ken (shiva@well.sf.ca.us)