]> SALOME platform Git repositories - modules/visu.git/commitdiff
Salome HOME
To disable debug action (dump to local file) T_22_03_05
authorapo <apo@opencascade.com>
Tue, 22 Mar 2005 14:13:37 +0000 (14:13 +0000)
committerapo <apo@opencascade.com>
Tue, 22 Mar 2005 14:13:37 +0000 (14:13 +0000)
src/VISU_I/VISU_DumpPython.cc

index 6fae6944cd6ff93158435247356b95523da4f112..251d46659045efcb0dadf2e2bef161363d302881 100644 (file)
@@ -1179,13 +1179,13 @@ namespace VISU{
 
 #ifndef COUT
     std::string aResult = aStr.str();
-    ofstream anFStream("/tmp/dump.py");
-    anFStream<<aResult<<endl;
+    //ofstream anFStream("/tmp/dump.py");
+    //anFStream<<aResult<<endl;
 
-    char* aBuffer = new char[aResult.size()+1];
-    strcpy(aBuffer, (char*)&aResult[0]);
-
-    return new Engines::TMPFile(aResult.size()+1, aResult.size()+1, (CORBA::Octet*)aBuffer, 1); 
+    CORBA::ULong aSize = aResult.size() + 1;
+    char* aBuffer = new char[aSize];
+    strcpy(aBuffer,&aResult[0]);
+    return new Engines::TMPFile(aSize,aSize,(CORBA::Octet*)aBuffer,1); 
 #else
 #undef aStr
     return new Engines::TMPFile(0);