Changeset 8de3388 in git


Ignore:
Timestamp:
Jul 15, 2010, 4:49:04 PM (13 years ago)
Author:
Andreas Steenpaß <steenpas@…>
Branches:
(u'jengelh-datetime', 'ceac47cbc86fe4a15902392bdbb9bd2ae0ea02c6')(u'spielwiese', 'a800fe4b3e9d37a38c5a10cc0ae9dfa0c15a4ee6')
Children:
1dba075fdedd6b7fdac018f3b79cfab9ba2a2e52
Parents:
6263f270b03890e5e7d11a4d6e8a10544a454c92
Message:

M    kernel/misc.cc
M    Singular/misc_ip.cc
automatically closes all links on exit


git-svn-id: file:///usr/local/Singular/svn/trunk@13019 2c84dea3-7e68-4137-9b89-c4e89433aadc
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • Singular/misc_ip.cc

    r6263f2 r8de3388  
    12461246}
    12471247
     1248/*2
     1249* the global exit routine of Singular
     1250*/
     1251#ifdef HAVE_MPSR
     1252void (*MP_Exit_Env_Ptr)()=NULL;
     1253#endif
     1254
     1255extern "C" {
     1256
     1257void m2_end(int i)
     1258{
     1259  fe_reset_input_mode();
     1260  #ifdef PAGE_TEST
     1261  mmEndStat();
     1262  #endif
     1263  #ifdef HAVE_TCL
     1264  if (tclmode)
     1265  {
     1266    PrintTCL('Q',0,NULL);
     1267  }
     1268  #endif
     1269  fe_reset_input_mode();
     1270  idhdl h = IDROOT;
     1271  while(h != NULL)
     1272  {
     1273    if(IDTYP(h) == LINK_CMD)
     1274    {
     1275      idhdl hh=h->next;
     1276      killhdl(h, currPack);
     1277      h = hh;
     1278    }
     1279    else
     1280    {
     1281      h = h->next;
     1282    }
     1283  }
     1284  if (i<=0)
     1285  {
     1286    #ifdef HAVE_TCL
     1287    if (!tclmode)
     1288    #endif
     1289      if (TEST_V_QUIET)
     1290      {
     1291        if (i==0)
     1292          printf("Auf Wiedersehen.\n");
     1293        else
     1294          printf("\n$Bye.\n");
     1295      }
     1296    //#ifdef sun
     1297    //  #ifndef __svr4__
     1298    //    _cleanup();
     1299    //    _exit(0);
     1300    //  #endif
     1301    //#endif
     1302    exit(0);
     1303  }
     1304  else
     1305  {
     1306    #ifdef HAVE_TCL
     1307    if (!tclmode)
     1308    #endif
     1309      printf("\nhalt %d\n",i);
     1310  }
     1311  #ifdef HAVE_MPSR
     1312  if (MP_Exit_Env_Ptr!=NULL) (*MP_Exit_Env_Ptr)();
     1313  #endif
     1314  exit(i);
     1315}
     1316}
  • kernel/misc.cc

    r6263f2 r8de3388  
    4949
    5050/*0 implementation*/
    51 
    52 /*2
    53 * the global exit routine of Singular
    54 */
    55 #ifdef HAVE_MPSR
    56 void (*MP_Exit_Env_Ptr)()=NULL;
    57 #endif
    58 extern "C" {
    59 
    60 void m2_end(int i)
    61 {
    62   fe_reset_input_mode();
    63   #ifdef PAGE_TEST
    64   mmEndStat();
    65   #endif
    66   #ifdef HAVE_TCL
    67   if (tclmode)
    68   {
    69     PrintTCL('Q',0,NULL);
    70   }
    71   #endif
    72   fe_reset_input_mode();
    73   if (i<=0)
    74   {
    75     #ifdef HAVE_TCL
    76     if (!tclmode)
    77     #endif
    78       if (TEST_V_QUIET)
    79       {
    80         if (i==0)
    81           printf("Auf Wiedersehen.\n");
    82         else
    83           printf("\n$Bye.\n");
    84       }
    85     //#ifdef sun
    86     //  #ifndef __svr4__
    87     //    _cleanup();
    88     //    _exit(0);
    89     //  #endif
    90     //#endif
    91     exit(0);
    92   }
    93   else
    94   {
    95     #ifdef HAVE_TCL
    96     if (!tclmode)
    97     #endif
    98       printf("\nhalt %d\n",i);
    99   }
    100   #ifdef HAVE_MPSR
    101   if (MP_Exit_Env_Ptr!=NULL) (*MP_Exit_Env_Ptr)();
    102   #endif
    103   exit(i);
    104 }
    105 }
    10651
    10752/*2
Note: See TracChangeset for help on using the changeset viewer.