[omniORB] Debug Assertion Failed although compiled with *.rtd.lib and run the Debug.exe?
Duncan Grisby
duncan@grisby.org
Thu Dec 12 11:15:02 2002
On Monday 9 December, "Uli Syber" wrote:
> idList= new Example::StringList(len);
> idList->length(len);
> (*idList)[0]=(L"Hello world");
> The message in the wstring array is correctly send form the server
> to the client but after that the omniORB server stops with the
> Assertion message.
What is the message?
Try changing the last line of code I've quoted to be
(*idList)[0]=(const CORBA::WChar*)(L"Hello world");
String and wstring literals are meant to be const in standard C++, but
VC++ might get it wrong, meaning the sequence tries to free the string
literal when it is deleted.
Cheers,
Duncan.
--
-- Duncan Grisby --
-- duncan@grisby.org --
-- http://www.grisby.org --