From 52659a35a4aa8347c3cecb863a4421a40bad3688 Mon Sep 17 00:00:00 2001 From: cascade Date: Fri, 13 Feb 2009 18:33:58 +0000 Subject: [PATCH] OCC20850 umake command do not work on SunOS10 --- src/WOKLibs/mscmd.cxx | 5 ++--- src/WOKLibs/wokcmd.cxx | 7 +++---- src/WOKLibs/woktoolscmd.cxx | 5 ++--- src/WOKLibs/wokutilscmd.cxx | 5 ++--- 4 files changed, 9 insertions(+), 13 deletions(-) diff --git a/src/WOKLibs/mscmd.cxx b/src/WOKLibs/mscmd.cxx index 526ab16..ec0b7bb 100755 --- a/src/WOKLibs/mscmd.cxx +++ b/src/WOKLibs/mscmd.cxx @@ -21,9 +21,6 @@ #include #include -//extern Standard_IMPORT Handle(WOKTclTools_Interpretor) CurrentInterp; -Standard_IMPORT Handle(WOKTclTools_Interpretor) CurrentInterp; - #ifdef WNT # ifdef _DEBUG extern "C" void _debug_break ( char* ); @@ -40,6 +37,8 @@ int Ms_Init(WOKTclTools_PInterp interp) OSD::SetSignal(); //==== Armed the signals. ============= + Handle(WOKTclTools_Interpretor)& CurrentInterp = WOKTclTools_Interpretor::Current(); + if(WOKTclTools_Interpretor::Current().IsNull()) { CurrentInterp = new WOKTclTools_Interpretor; diff --git a/src/WOKLibs/wokcmd.cxx b/src/WOKLibs/wokcmd.cxx index af96ba9..e43c537 100755 --- a/src/WOKLibs/wokcmd.cxx +++ b/src/WOKLibs/wokcmd.cxx @@ -32,9 +32,6 @@ #include -//extern Standard_IMPORT Handle(WOKTclTools_Interpretor) CurrentInterp; -Standard_IMPORT Handle(WOKTclTools_Interpretor) CurrentInterp; - #ifdef WNT # ifdef _DEBUG extern "C" void _debug_break ( char* ); @@ -60,6 +57,8 @@ int Wok_Init(WOKTclTools_PInterp interp) OSD::SetSignal(); //==== Armed the signals. ============= + Handle(WOKTclTools_Interpretor)& CurrentInterp = WOKTclTools_Interpretor::Current(); + if(WOKTclTools_Interpretor::Current().IsNull()) { CurrentInterp = new WOKTCL_Interpretor; @@ -156,7 +155,7 @@ int Wok_Init(WOKTclTools_PInterp interp) Handle(Standard_Failure) E = Standard_Failure::Caught(); Standard_SStream astream; astream << E << ends; - ErrorMsg << "WOKTCL_AppInit" << "Exception was raised : " << GetSString(astream) << endm; + ErrorMsg() << "WOKTCL_AppInit" << "Exception was raised : " << GetSString(astream) << endm; WOKUtils_ProcessManager::UnArm(); return TCL_ERROR; } diff --git a/src/WOKLibs/woktoolscmd.cxx b/src/WOKLibs/woktoolscmd.cxx index 469d9ed..f30fdd6 100755 --- a/src/WOKLibs/woktoolscmd.cxx +++ b/src/WOKLibs/woktoolscmd.cxx @@ -12,9 +12,6 @@ #include #include -//extern Standard_IMPORT Handle(WOKTclTools_Interpretor) CurrentInterp; -Standard_IMPORT Handle(WOKTclTools_Interpretor) CurrentInterp; - #ifdef WNT # ifdef _DEBUG extern "C" void _debug_break ( char* ); @@ -30,6 +27,8 @@ int Woktools_Init(WOKTclTools_PInterp interp) { OSD::SetSignal(); //==== Armed the signals. ============= + Handle(WOKTclTools_Interpretor)& CurrentInterp = WOKTclTools_Interpretor::Current(); + if(WOKTclTools_Interpretor::Current().IsNull()) { CurrentInterp = new WOKTclTools_Interpretor(interp); diff --git a/src/WOKLibs/wokutilscmd.cxx b/src/WOKLibs/wokutilscmd.cxx index e377810..65c5934 100755 --- a/src/WOKLibs/wokutilscmd.cxx +++ b/src/WOKLibs/wokutilscmd.cxx @@ -10,9 +10,6 @@ #include #include -//extern Standard_IMPORT Handle(WOKTclTools_Interpretor) CurrentInterp; -Standard_IMPORT Handle(WOKTclTools_Interpretor) CurrentInterp; - #ifdef WNT # ifdef _DEBUG extern "C" void _debug_break ( char* ); @@ -26,6 +23,8 @@ extern "C" int WOKUTILS_EXPORT Wokutils_Init(WOKTclTools_PInterp); int Wokutils_Init(WOKTclTools_PInterp interp) { + Handle(WOKTclTools_Interpretor)& CurrentInterp = WOKTclTools_Interpretor::Current(); + if(WOKTclTools_Interpretor::Current().IsNull()) { CurrentInterp = new WOKTclTools_Interpretor(interp); -- 2.39.5