felipe          Mon Jun 23 16:41:00 2008 UTC

  Modified files:              (Branch: PHP_5_3)
    /php-src/ext/posix  posix.c 
  Log:
  - Added arginfo
  
  
http://cvs.php.net/viewvc.cgi/php-src/ext/posix/posix.c?r1=1.70.2.3.2.16.2.7&r2=1.70.2.3.2.16.2.8&diff_format=u
Index: php-src/ext/posix/posix.c
diff -u php-src/ext/posix/posix.c:1.70.2.3.2.16.2.7 
php-src/ext/posix/posix.c:1.70.2.3.2.16.2.8
--- php-src/ext/posix/posix.c:1.70.2.3.2.16.2.7 Sun Jun 22 21:45:42 2008
+++ php-src/ext/posix/posix.c   Mon Jun 23 16:41:00 2008
@@ -16,7 +16,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: posix.c,v 1.70.2.3.2.16.2.7 2008/06/22 21:45:42 felipe Exp $ */
+/* $Id: posix.c,v 1.70.2.3.2.16.2.8 2008/06/23 16:41:00 felipe Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include "config.h"
@@ -56,91 +56,283 @@
 ZEND_DECLARE_MODULE_GLOBALS(posix)
 static PHP_MINFO_FUNCTION(posix);
 
+/* {{{ arginfo */
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_posix_kill, 0, 0, 2)
+       ZEND_ARG_INFO(0, pid)
+       ZEND_ARG_INFO(0, sig)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO(arginfo_posix_getpid, 0)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO(arginfo_posix_getppid, 0)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO(arginfo_posix_getuid, 0)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_posix_setuid, 0, 0, 1)
+       ZEND_ARG_INFO(0, uid)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO(arginfo_posix_geteuid, 0)
+ZEND_END_ARG_INFO()
+
+#ifdef HAVE_SETEUID
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_posix_seteuid, 0, 0, 1)
+       ZEND_ARG_INFO(0, uid)
+ZEND_END_ARG_INFO()
+#endif
+
+static
+ZEND_BEGIN_ARG_INFO(arginfo_posix_getgid, 0)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_posix_setgid, 0, 0, 1)
+       ZEND_ARG_INFO(0, gid)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO(arginfo_posix_getegid, 0)
+ZEND_END_ARG_INFO()
+
+#ifdef HAVE_SETEGID
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_posix_setegid, 0, 0, 1)
+       ZEND_ARG_INFO(0, gid)
+ZEND_END_ARG_INFO()
+#endif
+
+#ifdef HAVE_GETGROUPS
+static
+ZEND_BEGIN_ARG_INFO(arginfo_posix_getgroups, 0)
+ZEND_END_ARG_INFO()
+#endif
+
+#ifdef HAVE_GETLOGIN
+static
+ZEND_BEGIN_ARG_INFO(arginfo_posix_getlogin, 0)
+ZEND_END_ARG_INFO()
+#endif
+
+static
+ZEND_BEGIN_ARG_INFO(arginfo_posix_getpgrp, 0)
+ZEND_END_ARG_INFO()
+
+#ifdef HAVE_SETSID
+static
+ZEND_BEGIN_ARG_INFO(arginfo_posix_setsid, 0)
+ZEND_END_ARG_INFO()
+#endif
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_posix_setpgid, 0, 0, 2)
+       ZEND_ARG_INFO(0, pid)
+       ZEND_ARG_INFO(0, pgid)
+ZEND_END_ARG_INFO()
+
+#ifdef HAVE_GETPGID
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_posix_getpgid, 0, 0, 1)
+       ZEND_ARG_INFO(0, pid)
+ZEND_END_ARG_INFO()
+#endif
+
+#ifdef HAVE_GETSID
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_posix_getsid, 0, 0, 1)
+       ZEND_ARG_INFO(0, pid)
+ZEND_END_ARG_INFO()
+#endif
+
+static
+ZEND_BEGIN_ARG_INFO(arginfo_posix_uname, 0)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO(arginfo_posix_times, 0)
+ZEND_END_ARG_INFO()
+
+#ifdef HAVE_CTERMID
+static
+ZEND_BEGIN_ARG_INFO(arginfo_posix_ctermid, 0)
+ZEND_END_ARG_INFO()
+#endif
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_posix_ttyname, 0, 0, 1)
+       ZEND_ARG_INFO(0, fd)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_posix_isatty, 0, 0, 1)
+       ZEND_ARG_INFO(0, fd)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO(arginfo_posix_getcwd, 0)
+ZEND_END_ARG_INFO()
+
+#ifdef HAVE_MKFIFO
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_posix_mkfifo, 0, 0, 2)
+       ZEND_ARG_INFO(0, pathname)
+       ZEND_ARG_INFO(0, mode)
+ZEND_END_ARG_INFO()
+#endif
+
+#ifdef HAVE_MKNOD
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_posix_mknod, 0, 0, 2)
+       ZEND_ARG_INFO(0, pathname)
+       ZEND_ARG_INFO(0, mode)
+       ZEND_ARG_INFO(0, major)
+       ZEND_ARG_INFO(0, minor)
+ZEND_END_ARG_INFO()
+#endif
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_posix_access, 0, 0, 1)
+       ZEND_ARG_INFO(0, file)
+       ZEND_ARG_INFO(0, mode)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_posix_getgrnam, 0, 0, 1)
+       ZEND_ARG_INFO(0, name)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_posix_getgrgid, 0, 0, 1)
+       ZEND_ARG_INFO(0, gid)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_posix_getpwnam, 0, 0, 1)
+       ZEND_ARG_INFO(0, username)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_posix_getpwuid, 0, 0, 1)
+       ZEND_ARG_INFO(0, uid)
+ZEND_END_ARG_INFO()
+
+#ifdef HAVE_GETRLIMIT
+static
+ZEND_BEGIN_ARG_INFO(arginfo_posix_getrlimit, 0)
+ZEND_END_ARG_INFO()
+#endif
+
+static
+ZEND_BEGIN_ARG_INFO(arginfo_posix_get_last_error, 0)
+ZEND_END_ARG_INFO()
+
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_posix_strerror, 0, 0, 1)
+       ZEND_ARG_INFO(0, errno)
+ZEND_END_ARG_INFO()
+
+#ifdef HAVE_INITGROUPS
+static
+ZEND_BEGIN_ARG_INFO_EX(arginfo_posix_initgroups, 0, 0, 2)
+       ZEND_ARG_INFO(0, name)
+       ZEND_ARG_INFO(0, base_group_id)
+ZEND_END_ARG_INFO()
+#endif
+
 /* {{{ posix_functions[]
  */
 const zend_function_entry posix_functions[] = {
     /* POSIX.1, 3.3 */
-       PHP_FE(posix_kill,              NULL)
+       PHP_FE(posix_kill,              arginfo_posix_kill)
 
        /* POSIX.1, 4.1 */
-       PHP_FE(posix_getpid,    NULL)
-       PHP_FE(posix_getppid,   NULL)
+       PHP_FE(posix_getpid,    arginfo_posix_getpid)
+       PHP_FE(posix_getppid,   arginfo_posix_getppid)
 
        /* POSIX.1,  4.2 */
-       PHP_FE(posix_getuid,    NULL)
-       PHP_FE(posix_setuid,    NULL)
-       PHP_FE(posix_geteuid,   NULL)
+       PHP_FE(posix_getuid,    arginfo_posix_getuid)
+       PHP_FE(posix_setuid,    arginfo_posix_setuid)
+       PHP_FE(posix_geteuid,   arginfo_posix_geteuid)
 #ifdef HAVE_SETEUID
-       PHP_FE(posix_seteuid,   NULL)
+       PHP_FE(posix_seteuid,   arginfo_posix_seteuid)
 #endif
-       PHP_FE(posix_getgid,    NULL)
-       PHP_FE(posix_setgid,    NULL)
-       PHP_FE(posix_getegid,   NULL)
+       PHP_FE(posix_getgid,    arginfo_posix_getgid)
+       PHP_FE(posix_setgid,    arginfo_posix_setgid)
+       PHP_FE(posix_getegid,   arginfo_posix_getegid)
 #ifdef HAVE_SETEGID
-       PHP_FE(posix_setegid,   NULL)
+       PHP_FE(posix_setegid,   arginfo_posix_setegid)
 #endif
 #ifdef HAVE_GETGROUPS
-       PHP_FE(posix_getgroups, NULL)
+       PHP_FE(posix_getgroups, arginfo_posix_getgroups)
 #endif
 #ifdef HAVE_GETLOGIN
-       PHP_FE(posix_getlogin,  NULL)
+       PHP_FE(posix_getlogin,  arginfo_posix_getlogin)
 #endif
 
        /* POSIX.1, 4.3 */
-       PHP_FE(posix_getpgrp,   NULL)
+       PHP_FE(posix_getpgrp,   arginfo_posix_getpgrp)
 #ifdef HAVE_SETSID
-       PHP_FE(posix_setsid,    NULL)
+       PHP_FE(posix_setsid,    arginfo_posix_setsid)
 #endif
-       PHP_FE(posix_setpgid,   NULL)
+       PHP_FE(posix_setpgid,   arginfo_posix_setpgid)
        /* Non-Posix functions which are common */
 #ifdef HAVE_GETPGID
-       PHP_FE(posix_getpgid,   NULL)
+       PHP_FE(posix_getpgid,   arginfo_posix_getpgid)
 #endif /* HAVE_GETPGID */
 #ifdef HAVE_GETSID
-       PHP_FE(posix_getsid,    NULL)
+       PHP_FE(posix_getsid,    arginfo_posix_getsid)
 #endif /* HAVE_GETSID */
 
        /* POSIX.1, 4.4 */
-       PHP_FE(posix_uname,             NULL)
+       PHP_FE(posix_uname,             arginfo_posix_uname)
 
        /* POSIX.1, 4.5 */
-       PHP_FE(posix_times,             NULL)
+       PHP_FE(posix_times,             arginfo_posix_times)
 
        /* POSIX.1, 4.7 */
 #ifdef HAVE_CTERMID
-       PHP_FE(posix_ctermid,   NULL)
+       PHP_FE(posix_ctermid,   arginfo_posix_ctermid)
 #endif
-       PHP_FE(posix_ttyname,   NULL)
-       PHP_FE(posix_isatty,    NULL)
+       PHP_FE(posix_ttyname,   arginfo_posix_ttyname)
+       PHP_FE(posix_isatty,    arginfo_posix_isatty)
 
     /* POSIX.1, 5.2 */
-       PHP_FE(posix_getcwd,    NULL)
+       PHP_FE(posix_getcwd,    arginfo_posix_getcwd)
 
        /* POSIX.1, 5.4 */
 #ifdef HAVE_MKFIFO
-       PHP_FE(posix_mkfifo,    NULL)
+       PHP_FE(posix_mkfifo,    arginfo_posix_mkfifo)
 #endif
 #ifdef HAVE_MKNOD
-       PHP_FE(posix_mknod,     NULL)
+       PHP_FE(posix_mknod,             arginfo_posix_mknod)
 #endif
 
        /* POSIX.1, 5.6 */
-       PHP_FE(posix_access,    NULL)
+       PHP_FE(posix_access,    arginfo_posix_access)
        /* POSIX.1, 9.2 */
-       PHP_FE(posix_getgrnam,  NULL)
-       PHP_FE(posix_getgrgid,  NULL)
-       PHP_FE(posix_getpwnam,  NULL)
-       PHP_FE(posix_getpwuid,  NULL)
+       PHP_FE(posix_getgrnam,  arginfo_posix_getgrnam)
+       PHP_FE(posix_getgrgid,  arginfo_posix_getgrgid)
+       PHP_FE(posix_getpwnam,  arginfo_posix_getpwnam)
+       PHP_FE(posix_getpwuid,  arginfo_posix_getpwuid)
 
 #ifdef HAVE_GETRLIMIT
-       PHP_FE(posix_getrlimit, NULL)
+       PHP_FE(posix_getrlimit, arginfo_posix_getrlimit)
 #endif
 
-       PHP_FE(posix_get_last_error,                                    NULL)
+       PHP_FE(posix_get_last_error,                                    
arginfo_posix_get_last_error)
        PHP_FALIAS(posix_errno, posix_get_last_error,   NULL)
-       PHP_FE(posix_strerror,                                                  
NULL)
+       PHP_FE(posix_strerror,                                                  
arginfo_posix_strerror)
 #ifdef HAVE_INITGROUPS
-       PHP_FE(posix_initgroups,        NULL)
+       PHP_FE(posix_initgroups,        arginfo_posix_initgroups)
 #endif
 
        {NULL, NULL, NULL}
@@ -152,7 +344,7 @@
 static PHP_MINFO_FUNCTION(posix)
 {
        php_info_print_table_start();
-       php_info_print_table_row(2, "Revision", "$Revision: 1.70.2.3.2.16.2.7 
$");
+       php_info_print_table_row(2, "Revision", "$Revision: 1.70.2.3.2.16.2.8 
$");
        php_info_print_table_end();
 }
 /* }}} */

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

Reply via email to