diff options
author | Sterling Hughes <sterling@php.net> | 2001-09-03 21:54:27 +0000 |
---|---|---|
committer | Sterling Hughes <sterling@php.net> | 2001-09-03 21:54:27 +0000 |
commit | 55b600d03c323daf02a54dff7d7159ee1ac8f843 (patch) | |
tree | 20576cc8c8dce07c1741190d5e8b1fd83401de0e | |
parent | 1ecd31b66c1c81d6194963416c2b6f804790ea8f (diff) | |
download | php-git-55b600d03c323daf02a54dff7d7159ee1ac8f843.tar.gz |
fix compile on sun forte cc
-rw-r--r-- | ext/sablot/sablot.c | 33 |
1 files changed, 17 insertions, 16 deletions
diff --git a/ext/sablot/sablot.c b/ext/sablot/sablot.c index 228b52e298..f70ba9bb23 100644 --- a/ext/sablot/sablot.c +++ b/ext/sablot/sablot.c @@ -308,8 +308,12 @@ PHP_FUNCTION(xslt_output_endtransform) /* Nake sure there is data to send */ if (OG(active_ob_buffer).text_length) { - char *args[] = {"/_xmlinput", buffer, - "/_output", NULL}; + char *args[4]; + + args[0] = "/_xmlinput"; + args[1] = buffer; + args[2] = "/_output"; + args[3] = NULL; SABLOT_BASIC_CREATE_PROCESSOR(); @@ -491,6 +495,7 @@ PHP_FUNCTION(xslt_process) **input, **result, **base; + char *args[7]; char *tRes = NULL; int ret = 0, argc = ZEND_NUM_ARGS(); @@ -513,21 +518,17 @@ PHP_FUNCTION(xslt_process) SablotSetBase(SABLOT_BASIC_HANDLE, Z_STRVAL_PP(base)); } - /** - * Need to declare args here (to lazy to actually allocate - * it with emalloc() ;) - */ - { - char *args[] = {"/_stylesheet", Z_STRVAL_PP(xslt), - "/_xmlinput", Z_STRVAL_PP(input), - "/_output", NULL, - NULL}; - - ret = SablotRunProcessor(SABLOT_BASIC_HANDLE, "arg:/_stylesheet", - "arg:/_xmlinput", "arg:/_output", - NULL, args); - } + args[0] = "/_stylesheet"; + args[1] = Z_STRVAL_PP(xslt); + args[2] = "/_xmlinput"; + args[3] = Z_STRVAL_PP(input); + args[4] = "/_output"; + args[5] = NULL; + args[6] = NULL; + ret = SablotRunProcessor(SABLOT_BASIC_HANDLE, "arg:/_stylesheet", + "arg:/_xmlinput", "arg:/_output", + NULL, args); if (ret) { SABLOTG(last_errno) = ret; RETURN_FALSE; |