Changeset dc0898 in git


Ignore:
Timestamp:
Aug 2, 2000, 3:40:33 PM (23 years ago)
Author:
Olaf Bachmann <obachman@…>
Branches:
(u'jengelh-datetime', 'ceac47cbc86fe4a15902392bdbb9bd2ae0ea02c6')(u'spielwiese', 'c18334b998a8adbf0013b8e1ce0824774019443e')
Children:
ff4e84752079c82f72d2cff28527ed1b217ac9be
Parents:
e03066780716d0feba708e2349c879d0957c6ff2
Message:
* solved system problem under HPUX


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

Legend:

Unmodified
Added
Removed
  • Singular/cntrlc.cc

    re03066 rdc0898  
    22*  Computer Algebra System SINGULAR     *
    33****************************************/
    4 /* $Id: cntrlc.cc,v 1.30 2000-05-18 08:31:10 Singular Exp $ */
     4/* $Id: cntrlc.cc,v 1.31 2000-08-02 13:40:28 obachman Exp $ */
    55/*
    66* ABSTRACT - interupt handling
     
    2323#include "page.h"
    2424#endif
     25
    2526
    2627/* undef, if you don't want GDB to come up on error */
     
    627628#endif
    628629#endif
     630
     631/* Under HPUX 9, system(...) returns -1 if SIGCHLD does not equal
     632   SIG_DFL. However, if it stays at SIG_DFL we get zombie processes
     633   for terminated childs generated by fork. Therefors some special treatment
     634   is necessary */
     635#ifdef HPUX_9
     636#undef system
     637extern "C" {
     638  int  hpux9_system(const char* call)
     639  {
     640    int ret;
     641    signal(SIGCHLD, (void (*)(int))SIG_DFL);
     642    ret = system(call);
     643    signal(SIGCHLD, (void (*)(int))SIG_IGN);
     644    return ret;
     645  }
     646}
     647#endif /* HPUX_9 */
  • Singular/emacs.cc

    re03066 rdc0898  
    22*  Computer Algebra System SINGULAR     *
    33****************************************/
    4 /* $Id: emacs.cc,v 1.15 2000-05-08 15:35:09 obachman Exp $ */
     4/* $Id: emacs.cc,v 1.16 2000-08-02 13:40:28 obachman Exp $ */
    55/*
    66* ABSTRACT: Esingular main file
     
    1919#if !defined(TSINGULAR) && !defined(ESINGULAR)
    2020#define ESINGULAR
     21#endif
     22
     23#ifdef system
     24#undef system
    2125#endif
    2226
  • Singular/extra.cc

    re03066 rdc0898  
    22*  Computer Algebra System SINGULAR      *
    33*****************************************/
    4 /* $Id: extra.cc,v 1.135 2000-05-22 09:39:51 Singular Exp $ */
     4/* $Id: extra.cc,v 1.136 2000-08-02 13:40:30 obachman Exp $ */
    55/*
    66* ABSTRACT: general interface to internals of Singular ("system" command)
     
    173173      res->rtyp=INT_CMD;
    174174      #ifndef __MWERKS__
    175       #ifdef HPUX_9
    176       signal(SIGCHLD, (void (*)(int))SIG_DFL);
    177       #endif
    178175      if (h==NULL) res->data = (void *)system("sh");
    179176      else if (h->Typ()==STRING_CMD)
     
    181178      else
    182179        WerrorS("string expected");
    183       #ifdef HPUX_9
    184       signal(SIGCHLD, (void (*)(int))SIG_IGN);
    185       #endif
    186180      #else
    187181      res->data=(void *)0;
  • Singular/fehelp.cc

    re03066 rdc0898  
    808808
    809809  // --remote exits with status != 0 if netscaep isn't already running
    810  #ifdef HPUX_9
    811  signal(SIGCHLD, (void (*)(int))SIG_DFL);
    812  #endif
    813810  if (system(sys) != 0)
    814811  {
     
    823820    }
    824821  }
    825  #ifdef HPUX_9
    826  signal(SIGCHLD, (void (*)(int))SIG_IGN);
    827  #endif
    828822}
    829823
  • Singular/mod2.h.in

    re03066 rdc0898  
    66 *          DO NOT EDIT!
    77 *
    8  *  Version: $Id: mod2.h.in,v 1.82 2000-04-27 10:07:09 obachman Exp $
     8 *  Version: $Id: mod2.h.in,v 1.83 2000-08-02 13:40:33 obachman Exp $
    99 *******************************************************************/
    1010#ifndef MOD2_H
     
    272272#define MM_COUNT 1
    273273
     274/* Under HPUX 9, system(...) returns -1 if SIGCHLD does not equal
     275   SIG_DFL. However, if it stays at SIG_DFL we get zombie processes
     276   for terminated childs generated by fork. Therefors some special treatment
     277   is necessary */
     278#ifdef HPUX_9
     279#include <stdlib.h>
     280#define system hpux9_system
     281#ifdef __cplusplus
     282extern "C" {
     283#endif
     284int hpux9_system(const char* system);
     285#ifdef __cplusplus
     286}
     287#endif
     288#endif
    274289
    275290#ifndef HAVE_LIBPARSER
Note: See TracChangeset for help on using the changeset viewer.