From: adam Date: Thu, 26 Feb 2009 14:57:12 +0000 (+0000) Subject: Compatibility windows X-Git-Tag: V5_1_1a2~5 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=4240f05b239beffc0416f28c2e9d3d12c803bedf;p=modules%2Fgeom.git Compatibility windows --- diff --git a/src/GEOM_I/GEOM_Gen_i.cc b/src/GEOM_I/GEOM_Gen_i.cc index 6e8e4e430..9a0ee0d63 100644 --- a/src/GEOM_I/GEOM_Gen_i.cc +++ b/src/GEOM_I/GEOM_Gen_i.cc @@ -1471,10 +1471,12 @@ char* GEOM_Gen_i::getObjectInfo(CORBA::Long studyId, const char* entry) } } - char anInfo [strlen("Module ") + strlen(ComponentDataType()) + strlen(", ") + strlen(aTypeInfo)]; + char* anInfo = new char[strlen("Module ") + strlen(ComponentDataType()) + strlen(", ") + strlen(aTypeInfo) + 3]; sprintf(anInfo, "Module %s, %s", ComponentDataType(), aTypeInfo); - return CORBA::string_dup(anInfo); + char* ret = CORBA::string_dup(anInfo); + delete [] anInfo; + return ret; } //=====================================================================================