Salome HOME
Updated copyright comment
[modules/smesh.git] / src / DriverUNV / DriverUNV_R_SMDS_Mesh.cxx
index 6ebc03eeb46e1b9657f9615c36601a2aa1612923..a489c4cddecd3884bdcbde013bd322c8ad13840d 100644 (file)
@@ -1,4 +1,4 @@
-// Copyright (C) 2007-2016  CEA/DEN, EDF R&D, OPEN CASCADE
+// Copyright (C) 2007-2024  CEA, EDF, OPEN CASCADE
 //
 // Copyright (C) 2003-2007  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
 // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
 
 using namespace std;
 
-
-#ifdef _DEBUG_
-static int MYDEBUG = 0;
-#else
-static int MYDEBUG = 0;
-#endif
-
 namespace
 {
   /*!
@@ -102,7 +95,12 @@ Driver_Mesh::Status DriverUNV_R_SMDS_Mesh::Perform()
 {
   Kernel_Utils::Localizer loc;
   Status aResult = DRS_OK;
+#if defined(WIN32) && defined(UNICODE)
+  std::wstring aFile = Kernel_Utils::utf8_decode_s(myFile);
+  std::ifstream in_stream(aFile.c_str());
+#else
   std::ifstream in_stream(myFile.c_str());
+#endif
   try
   {
     {
@@ -118,7 +116,7 @@ Driver_Mesh::Status DriverUNV_R_SMDS_Mesh::Perform()
       using namespace UNV2411;
       TDataSet aDataSet2411;
       UNV2411::Read(in_stream,aDataSet2411);
-      if(MYDEBUG) MESSAGE("Perform - aDataSet2411.size() = "<<aDataSet2411.size());
+      MESSAGE("Perform - aDataSet2411.size() = "<<aDataSet2411.size());
 
       // Move nodes in a global CS
       if ( !aCoordSysDataSet.empty() )
@@ -163,7 +161,7 @@ Driver_Mesh::Status DriverUNV_R_SMDS_Mesh::Perform()
       TDataSet aDataSet2412;
       UNV2412::Read(in_stream,aDataSet2412);
       TDataSet::const_iterator anIter = aDataSet2412.begin();
-      if(MYDEBUG) MESSAGE("Perform - aDataSet2412.size() = "<<aDataSet2412.size());
+      MESSAGE("Perform - aDataSet2412.size() = "<<aDataSet2412.size());
       for(; anIter != aDataSet2412.end(); anIter++)
       {
         SMDS_MeshElement* anElement = NULL;
@@ -399,7 +397,7 @@ Driver_Mesh::Status DriverUNV_R_SMDS_Mesh::Perform()
       using namespace UNV2417;
       TDataSet aDataSet2417;
       UNV2417::Read(in_stream,aDataSet2417);
-      if(MYDEBUG) MESSAGE("Perform - aDataSet2417.size() = "<<aDataSet2417.size());
+      MESSAGE("Perform - aDataSet2417.size() = "<<aDataSet2417.size());
       if (aDataSet2417.size() > 0)
       {
         TDataSet::const_iterator anIter = aDataSet2417.begin();