hyanantha               Fri Jan  3 11:06:03 2003 EDT

  Modified files:              
    /php4/ext/standard  exec.c 
  Log:
  Modified for NetWare.
  
  
Index: php4/ext/standard/exec.c
diff -u php4/ext/standard/exec.c:1.89 php4/ext/standard/exec.c:1.90
--- php4/ext/standard/exec.c:1.89       Fri Jan  3 09:37:40 2003
+++ php4/ext/standard/exec.c    Fri Jan  3 11:06:02 2003
@@ -15,7 +15,7 @@
    | Author: Rasmus Lerdorf                                               |
    +----------------------------------------------------------------------+
  */
-/* $Id: exec.c,v 1.89 2003/01/03 14:37:40 hyanantha Exp $ */
+/* $Id: exec.c,v 1.90 2003/01/03 16:06:02 hyanantha Exp $ */
 
 #include <stdio.h>
 #include "php.h"
@@ -599,13 +599,13 @@
        le_proc_open = zend_register_list_destructors_ex(proc_open_rsrc_dtor, NULL, 
"process", module_number);
        return SUCCESS;
 }
-
 /* }}} */
 
 /* {{{ proto int proc_close(resource process)
    close a process opened by proc_open */
 PHP_FUNCTION(proc_close)
 {
+#ifndef NETWARE        /* This is removed for NetWare because there is not way to 
+execute a new process using fork() */
        zval *proc;
        void *child;
        
@@ -617,6 +617,7 @@
        
        zend_list_delete(Z_LVAL_P(proc));
        RETURN_LONG(FG(pclose_ret));
+#endif /* NETWARE */
 }
 /* }}} */
 
@@ -667,6 +668,8 @@
    Run a process with more control over it's file descriptors */
 PHP_FUNCTION(proc_open)
 {
+#ifndef NETWARE        /* This is removed for NetWare because there is not way to 
+execute a new process using fork() */
+
 #define MAX_DESCRIPTORS        16
 
        char *command;
@@ -896,18 +899,6 @@
        child = pi.hProcess;
        CloseHandle(pi.hThread);
 
-#elif defined(NETWARE)
-
-       /* clean up all the descriptors */
-       for (i = 0; i < ndesc; i++) {
-               close(descriptors[i].childend);
-               close(descriptors[i].parentend);
-       }
-
-       php_error_docref(NULL TSRMLS_CC, E_WARNING, "fork not supported on NetWare");
-
-       goto exit_fail;
-
 #else
        /* the unix way */
 
@@ -1008,7 +999,7 @@
        efree(command);
        RETURN_FALSE;
 
-       
+#endif /* NETWARE */
 }
 /* }}} */
 



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to