-// Copyright (C) 2007-2014 CEA/DEN, EDF R&D, OPEN CASCADE
+// Copyright (C) 2007-2021 CEA/DEN, EDF R&D, OPEN CASCADE
//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
#include "SALOMESDS_Exception.hxx"
SALOMESDS::Exception::Exception(const std::string& reason)
+{
+ this->assign(reason.c_str());
+}
+
+SALOMESDS::Exception::Exception(const char *reason)
+{
+ this->assign(reason);
+}
+
+void SALOMESDS::Exception::assign(const char *reason)
{
SALOME::ExceptionStruct es;
es.type=SALOME::INTERNAL_ERROR;
- es.text=CORBA::string_dup(reason.c_str());
+ es.text=CORBA::string_dup(reason);
es.lineNumber=0;
(*this).details=es;
}
-
-