[omniORB] String handling problem with VC7.1

Ecker Severin Severin.Ecker at arcs.ac.at
Thu Mar 22 17:16:03 GMT 2007


Hi,

I'm wondering if I'm just using CORBA in an incorrect way or if there
really is an issue but whenever I try to use the following code I get an
debug assertion failure:

Code I'm trying to get to work:

CosNaming::Name var;
var.length(1);
var[0].id = (const char*)"test";


the assertion failuer happens here:
stringtypes.h

in the _CORBA_String_helper class

static inline void free(char* s) { 
  if (s && s != empty_string) delete[] s; 
}

For some reason the condition hold true and attempts are made to delete
an invalid string resource. As you can see above I just want to assign a
string to a completely new and fresh corba object (the id string) which
does have the value 'empty_string' at the time of my assignment
statement.

Hope someone can help me!

Thanks in advance!

Best regards,
severin




More information about the omniORB-list mailing list