0022898: IGES import fails in german environment
[occt.git] / src / DNaming / DNaming_BasicCommands.cxx
index 71fc4ae..96d4cee 100755 (executable)
@@ -88,7 +88,7 @@ static Standard_Integer Ascendants (Draw_Interpretor& di, Standard_Integer n, co
 
   Standard_Integer T;
 
-  if (n > 3) T = atoi(a[3]);
+  if (n > 3) T = Draw::Atoi(a[3]);
   else       T = ND->Transaction ();
 
   //TNaming_OldShapeIterator it (S, T, US);  
@@ -97,7 +97,7 @@ static Standard_Integer Ascendants (Draw_Interpretor& di, Standard_Integer n, co
   TCollection_AsciiString entry;
   for (;it.More (); it.Next ()) {
     S = it.Shape ();
-    sprintf (name,"%s_%s_%d",a[2],"old", i++);
+    Sprintf (name,"%s_%s_%d",a[2],"old", i++);
     DBRep::Set (name,it.Shape());
     TDF_Label Label = it.Label ();
     TDF_Tool::Entry(Label,entry);
@@ -128,7 +128,7 @@ static Standard_Integer Descendants (Draw_Interpretor& di, Standard_Integer n, c
 
   Standard_Integer T;
 
-  if (n > 3) T = atoi(a[3]);
+  if (n > 3) T = Draw::Atoi(a[3]);
   else       T = ND->Transaction ();
 
   TNaming_NewShapeIterator it (S, T, ND->Root());
@@ -136,7 +136,7 @@ static Standard_Integer Descendants (Draw_Interpretor& di, Standard_Integer n, c
   TCollection_AsciiString entry;
   for (;it.More (); it.Next ()) {
     S = it.Shape ();
-    sprintf (name,"%s_%s_%d",a[2],"new", i++);
+    Sprintf (name,"%s_%s_%d",a[2],"new", i++);
     DBRep::Set (name,it.Shape ());
     TDF_Label Label = it.Label ();
     TDF_Tool::Entry(Label,entry);
@@ -281,7 +281,7 @@ static Standard_Integer Exploreshape (Draw_Interpretor& di, Standard_Integer n,
 //  ND->Root().FindAttribute(TNaming_UsedShapes::GetID(),US);
   
   Standard_Integer Trans = ND->Transaction();
-  if (n == 5) { Trans = (Standard_Integer ) atof(a[4]);}
+  if (n == 5) { Trans = (Standard_Integer ) Draw::Atof(a[4]);}
   
   TDF_Label Lab;
   DDF::FindLabel(ND,a[2],Lab);
@@ -300,11 +300,11 @@ static Standard_Integer Exploreshape (Draw_Interpretor& di, Standard_Integer n,
   
   for (TNaming_Iterator itL(Lab,Trans) ; itL.More(); itL.Next()) {
     if (!itL.OldShape().IsNull()) {
-      sprintf(name,"%s%s_%d","old",a[3],NbShapes);
+      Sprintf(name,"%s%s_%d","old",a[3],NbShapes);
       DBRep::Set (name,itL.OldShape());
     }
     if (!itL.NewShape().IsNull()) {    
-      sprintf(name,"%s_%d",a[3],NbShapes);
+      Sprintf(name,"%s_%d",a[3],NbShapes);
       DBRep::Set (name,itL.NewShape());
     }
     NbShapes++;
@@ -388,7 +388,7 @@ static Standard_Integer Collect (Draw_Interpretor& di,
     if (!DDF::GetDF(arg[1],DF)) return 1;
     if (!DDF::Find(DF,arg[2],TNaming_NamedShape::GetID(),A)) return 1;
     if (nb >= 4) {
-      OnlyModif = atoi(arg[3]);
+      OnlyModif = Draw::Atoi(arg[3]);
     }
     TNaming_Tool::Collect(A,MNS,OnlyModif);
     for (TNaming_MapIteratorOfMapOfNamedShape it(MNS); it.More(); it.Next()) {