Home » U++ Library support » U++ Library : Other (not classified elsewhere) » WString0::Free() crashing
WString0::Free() crashing [message #40668] |
Thu, 29 August 2013 22:32 |
crydev
Messages: 151 Registered: October 2012 Location: Netherlands
|
Experienced Member |
|
|
Hello,
I am experiencing a crash that I cannot identify. When assigning a new wchar buffer to a WString class, I sometimes experience erors. Sometimes this does not occur, but sometimes it does. The crash it at:
inline int AtomicDec(volatile Atomic& t) { return InterlockedDecrement((Atomic *)&t); }
The calling code is:
WString* localValues; // just to show what type the array is, this is fully initialized so no problems here.
const wchar* strPtr = (const wchar*)&(buffer[i]);
localValues[arrayIndex++] = WString(strPtr, value.GetLength()); // value.GetLength() is the length of the string, say 5.
The usual String class does not produce errors, while the assignment method is exactly the same. Why does it crash? I am using Win32 ofcourse.
Thanks, crydev
[Updated on: Thu, 29 August 2013 22:33] Report message to a moderator
|
|
|
Goto Forum:
Current Time: Thu Mar 28 13:06:30 CET 2024
Total time taken to generate the page: 0.00800 seconds
|