Changeset 46e869 in git for Singular


Ignore:
Timestamp:
Aug 7, 2013, 5:29:57 PM (11 years ago)
Author:
Hans Schoenemann <hannes@…>
Branches:
(u'spielwiese', '17f1d200f27c5bd38f5dfc6e8a0879242279d1d8')
Children:
32a5f7cbaed7a5ea97ad30c9863f455d9cc4cef2
Parents:
52f95b2cdc569ae8b09e7182d80a56a57fcef2f7
Message:
add: system("semaphore",...)
Location:
Singular
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • Singular/extra.cc

    r52f95b r46e869  
    171171#ifdef HAVE_GMS
    172172#include "gms.h"
     173#endif
     174
     175#ifdef HAVE_SIMPLEIPC
     176#include "Singular/links/simpleipc.h"
    173177#endif
    174178
     
    37963800
    37973801  #endif
     3802/*==================== semaphore =================*/
     3803#ifdef HAVE_SIMPLEIPC
     3804    if (strcmp(sys_cmd,"semaphore")==0)
     3805    {
     3806      if((h!=NULL) && (h->Typ()==STRING_CMD) && (h->next!=NULL) && (h->next->Typ()==INT_CMD))
     3807      {
     3808        int v=1;
     3809        if ((h->next->next!=NULL)&& (h->next->next->Typ()==INT_CMD))
     3810          v=(int)(long)h->next->next->Data();
     3811        res->data=(char *)simpleipc_cmd((char *)h->Data(),(int)(long)h->next->Data(),v);
     3812        res->rtyp=INT_CMD;
     3813        return FALSE;
     3814      }
     3815      else
     3816      {
     3817        WerrorS("Usage: system(\"semaphore\",<cmd>,int)");
     3818        return TRUE;
     3819      }
     3820    }
     3821    else
     3822#endif
    37983823/*======================= demon_list =====================*/
    37993824  if (strcmp(sys_cmd,"denom_list")==0)
  • Singular/iparith.cc

    r52f95b r46e869  
    3535
    3636
    37 #include <kernel/modulop.h>
    3837#include <kernel/stairc.h>
    3938#include <kernel/mod2.h>
Note: See TracChangeset for help on using the changeset viewer.