Changeset a2fa63f in tol
- Timestamp:
- Aug 4, 2015, 11:00:39 AM (11 years ago)
- Branches:
- 1941-docker-image-to-test, devel, master
- Children:
- da4a80a7
- Parents:
- 6605c6c
- File:
-
- 1 edited
-
tol/init.cpp (modified) (10 diffs)
Legend:
- Unmodified
- Added
- Removed
-
tol/init.cpp
r6605c6c ra2fa63f 184 184 185 185 //-------------------------------------------------------------------- 186 static void Error_UnexpectedTolEnd(void)187 //--------------------------------------------------------------------188 {189 Error(I2("An unexpected error has made TOL unstable and session must be closed",190 "Un error inesperado ha hecho TOL inestable y la sesión debe ser cerrada"));191 }192 193 //--------------------------------------------------------------------194 TOL_API void UnexpectedTolEnd(void)195 //--------------------------------------------------------------------196 {197 Error_UnexpectedTolEnd();198 SetTOLEnd();199 }200 201 //--------------------------------------------------------------------202 static void signal_error_SIGABRT(int sig)203 //--------------------------------------------------------------------204 {205 Error("SIGNAL: Abnormal termination, such as instigated by the abort function. (Abort.)");206 Error_UnexpectedTolEnd();207 exit(sig);208 };209 210 //--------------------------------------------------------------------211 static void signal_error_SIGFPE(int sig)212 //--------------------------------------------------------------------213 {214 Error("SIGNAL: Erroneous arithmetic operation, such as divide by 0 or overflow. (Floating point exception.)");215 Error_UnexpectedTolEnd();216 exit(sig);217 };218 219 //--------------------------------------------------------------------220 static void signal_error_SIGILL(int sig)221 //--------------------------------------------------------------------222 {223 Error("SIGNAL: An invalid object program has been detected. This usually means that there is an illegal instruction in the program. (Illegal instruction.)");224 Error_UnexpectedTolEnd();225 exit(sig);226 };227 228 //--------------------------------------------------------------------229 186 static void signal_error_SIGINT(int sig) 230 187 //-------------------------------------------------------------------- … … 245 202 time( tm0 ); 246 203 } 204 } 205 206 #if !defined(UNIX) 207 208 //-------------------------------------------------------------------- 209 static void Error_UnexpectedTolEnd(void) 210 //-------------------------------------------------------------------- 211 { 212 Error(I2("An unexpected error has made TOL unstable and session must be closed", 213 "Un error inesperado ha hecho TOL inestable y la sesión debe ser cerrada")); 214 } 215 216 //-------------------------------------------------------------------- 217 TOL_API void UnexpectedTolEnd(void) 218 //-------------------------------------------------------------------- 219 { 220 Error_UnexpectedTolEnd(); 221 SetTOLEnd(); 222 } 223 224 //-------------------------------------------------------------------- 225 static void signal_error_SIGABRT(int sig) 226 //-------------------------------------------------------------------- 227 { 228 Error("SIGNAL: Abnormal termination, such as instigated by the abort function. (Abort.)"); 229 Error_UnexpectedTolEnd(); 230 exit(sig); 231 }; 232 233 //-------------------------------------------------------------------- 234 static void signal_error_SIGFPE(int sig) 235 //-------------------------------------------------------------------- 236 { 237 Error("SIGNAL: Erroneous arithmetic operation, such as divide by 0 or overflow. (Floating point exception.)"); 238 Error_UnexpectedTolEnd(); 239 exit(sig); 240 }; 241 242 //-------------------------------------------------------------------- 243 static void signal_error_SIGILL(int sig) 244 //-------------------------------------------------------------------- 245 { 246 Error("SIGNAL: An invalid object program has been detected. This usually means that there is an illegal instruction in the program. (Illegal instruction.)"); 247 Error_UnexpectedTolEnd(); 248 exit(sig); 247 249 }; 248 250 … … 281 283 exit(sig); 282 284 }; 285 286 #endif 283 287 284 288 //-------------------------------------------------------------------- … … 323 327 //signal( 19, signal_error_SIGUNK); 324 328 //signal( 20, signal_error_SIGUNK); 325 /**/329 */ 326 330 #endif 327 331 } … … 934 938 #endif 935 939 BText svnInfo = __TOL_BUILD_SVN_INFO__; 936 BSystemText* SvnInfo_ =new BSystemText940 new BSystemText 937 941 ("SvnInfo", svnInfo, 938 942 I2("Contains the information on the SVN URL and revision number from which TOL was compiled", … … 959 963 int blnk_pos_2 = _tolVersion_.Find(' ', blnk_pos_1+1); 960 964 961 BSystemText* TolReleaseId_ =new BSystemText("TolReleaseId",962 BText(_tolVersion_,0,blnk_pos_2-1),963 I2("Time Oriented Language release identifier.",964 "Identificador de la publicación de la versión Time Oriented Language."));965 966 BSystemText* TolVersionId_ =new BSystemText("TolVersionId",967 BText(_tolVersion_,0,blnk_pos_1-1),968 I2("Time Oriented Language version identifier.",969 "Identificador de la versión Time Oriented Language."));965 new BSystemText("TolReleaseId", 966 BText(_tolVersion_,0,blnk_pos_2-1), 967 I2("Time Oriented Language release identifier.", 968 "Identificador de la publicación de la versión Time Oriented Language.")); 969 970 new BSystemText("TolVersionId", 971 BText(_tolVersion_,0,blnk_pos_1-1), 972 I2("Time Oriented Language version identifier.", 973 "Identificador de la versión Time Oriented Language.")); 970 974 971 975 BText TOLAppName = ToLower(GetFilePrefix(_tolSessionPath_)); 972 BSystemText* TOLAppName_ =new BSystemText("TOLAppName",973 TOLAppName,974 I2("The name of the TOL executable",975 "Nombre del ejecutable TOL."));976 new BSystemText("TOLAppName", 977 TOLAppName, 978 I2("The name of the TOL executable", 979 "Nombre del ejecutable TOL.")); 976 980 977 981 BText TOLSH_PATH = BSys::GetEnv("TOLSH_PATH"); … … 980 984 TOLSH_PATH = GetFilePath(_tolSessionPath_); 981 985 } 982 BSystemText* TOLSH_PATH_ =new BSystemText("TOLSH_PATH",983 TOLSH_PATH,984 I2("The path of the TOL executable",985 "Ubicación del ejecutable TOL."));986 new BSystemText("TOLSH_PATH", 987 TOLSH_PATH, 988 I2("The path of the TOL executable", 989 "Ubicación del ejecutable TOL.")); 986 990 987 991 #ifdef UNIX … … 1001 1005 InitRefStructs(); 1002 1006 1003 BStruct* strStructFieldInfo_ =NewStruct("@StructFieldInfo",1004 "Text:Type,"1005 "Text:Name,"1006 "Text:Description");1007 NewStruct("@StructFieldInfo", 1008 "Text:Type," 1009 "Text:Name," 1010 "Text:Description"); 1007 1011 1008 1012 TOLHasBeenInitialized_ = true; … … 1559 1563 //-------------------------------------------------------------------- 1560 1564 { 1561 int aliveObjects_1 = 0, aliveObjects_2 = 0; 1562 int aliveObjects_1_ = 0, aliveObjects_2_ = 0; 1565 // unused 1566 int /*aliveObjects_1 = 0,*/ aliveObjects_2 = 0; 1567 // unused 1568 int /*aliveObjects_1_ = 0,*/ aliveObjects_2_ = 0; 1563 1569 InitVerboseMode(); 1564 1570 BText::PutFormatBReal("%lf"); … … 1727 1733 { 1728 1734 InitGrammars(argv[0]); 1729 aliveObjects_1 = AliveObjects(); 1735 // unused 1736 /*aliveObjects_1 =*/ AliveObjects(); 1730 1737 if(initTOL) { LoadInitLibrary(loadInitProject,loadDefaultPackages); } 1731 1738 aliveObjects_2 = AliveObjects();
Note: See TracChangeset
for help on using the changeset viewer.
