]> git.pld-linux.org Git - packages/php.git/blob - php-dextension.patch
- merged from php4.spec and adjusted for Ra
[packages/php.git] / php-dextension.patch
1 backported loading dl extension with -dexetnsion=extension.so from php5.1-200512091130
2
3 --- php-5.0.5/sapi/cli/php_cli.c        2005-03-22 17:09:20.000000000 +0200
4 +++ php5.1-200512091130/sapi/cli/php_cli.c      2005-12-10 01:11:54.000000000 +0200
5 @@ -397,7 +397,7 @@
6  }
7  /* }}} */
8  
9 -static void define_command_line_ini_entry(char *arg)
10 +static void define_command_line_ini_entry(char *arg TSRMLS_DC)
11  {
12         char *name, *value;
13  
14 @@ -409,7 +409,14 @@
15         } else {
16                 value = "1";
17         }
18 -       zend_alter_ini_entry(name, strlen(name)+1, value, strlen(value), PHP_INI_SYSTEM, PHP_INI_STAGE_ACTIVATE);
19 +
20 +       if (!strcasecmp(name, "extension")) { /* load function module */
21 +               zval extension, zval;
22 +               ZVAL_STRING(&extension, value, 0);
23 +               php_dl(&extension, MODULE_PERSISTENT, &zval TSRMLS_CC);
24 +       } else {
25 +               zend_alter_ini_entry(name, strlen(name)+1, value, strlen(value), PHP_INI_SYSTEM, PHP_INI_STAGE_ACTIVATE);
26 +       }
27  }
28  
29  
30 @@ -656,7 +663,7 @@
31                         switch (c) {
32  
33                         case 'd': /* define ini entries on command line */
34 -                               define_command_line_ini_entry(php_optarg);
35 +                               define_command_line_ini_entry(php_optarg TSRMLS_CC);
36                                 break;
37  
38                         case 'h': /* help & quit */
This page took 0.043388 seconds and 3 git commands to generate.