Ecker Severin
2007-03-23 12:56:09 UTC
Hi all,
I've checked the libs and to me they seem to be the correct ones
(meaning I'm using the debug libs for my debug code)
static inline void free(char* s) {
if (s && s != empty_string) delete[] s;
}
s indeed does have the same value as empty_string according to the
debugger and using the exact same code outside of the lib in my
application it does work fine. It just fails when code runs through this
function in the corba lib ;/
cheers,
severin
I suspect that you are using non-debug and debug versions of MS C
runtime library: one is used by the omniORB and the other is used by
your application.
runtime library: one is used by the omniORB and the other is used by
your application.
(meaning I'm using the debug libs for my debug code)
I would say,the problem is, when you assign the constant pointer to
var.id, var assumes ownership of the memory pointed to, and it will
attempt to free it, when the variable releases ownership of it.
CosNaming::Name behaves like _var types in that respect, and your
runtime is quite right to complain about freeing string constants.
I doubt that because the weird thing is invar.id, var assumes ownership of the memory pointed to, and it will
attempt to free it, when the variable releases ownership of it.
CosNaming::Name behaves like _var types in that respect, and your
runtime is quite right to complain about freeing string constants.
static inline void free(char* s) {
if (s && s != empty_string) delete[] s;
}
s indeed does have the same value as empty_string according to the
debugger and using the exact same code outside of the lib in my
application it does work fine. It just fails when code runs through this
function in the corba lib ;/
cheers,
severin