[PHP-DEV] Help, please! The Zend API is driving me mad!!!

2003-06-17 Thread Oriol
Aaargh! When I run the following code... -- char fname[256]; zval **retval; zval *zfname; strcpy(fname, "rand"); zend_printf("Step 1...\n"); MAKE_STD_ZVAL(zfname); zend_printf("Step 2...\n"); ZVAL_STR

[PHP-DEV] gdb php5 broken? gdb reading values for variables from wrong addresses

2003-06-17 Thread Henry
Hi, I'm running gdb 5.3 under Red Hat 7.2 (up2date'd) on php5 CGI with the "broken" RH 2.96-112.7.2 gcc. However, when I try to print variables within gdb, gdb tries to print variables using the wrong addresses in VM (off by a some hundreds of bytes). I can add code to the source code such that

Re: [PHP-DEV] Help, please! The Zend API is driving me mad!!!

2003-06-17 Thread Joao Prado Maia
My code is just as bad, but I remember that it used to work: PHP_FUNCTION(jtemplate_set_root) { zval **z_root_dir; char *root_dir = NULL; int argc = ZEND_NUM_ARGS(); zval func; zval *retval = NULL; zval *args[1]; if (argc < 0 || arg

Re: [PHP-DEV] Help, please! The Zend API is driving me mad!!!

2003-06-17 Thread Marcus Börger
Hello Oriol, Tuesday, June 17, 2003, 6:29:14 PM, you wrote: O> Aaargh! O> When I run the following code... O> -- O> char fname[256]; O> zval **retval; O> zval *zfname; O> strcpy(fname, "rand"); O> zend_printf("

[PHP-DEV] retrieving and setting vars from own extension?

2003-06-17 Thread Thomas Seifert
Hi folks, sorry but I couldn't find the answer in the docs at php.net and google didn't turn out anything usefull to. I'm trying to write my own extension which would need to retrieve and set (global) variables for the php-script its called from. But I just can't find a way to do this in the doc

Re: [PHP-DEV] The aggregation/Zend hash bug

2003-06-17 Thread Wei He
Hi, I seems my suspiction is right as I didn't receive any reply from andrei. So I post it to the list this time. According to my deeper analysis. Unsetting an object will not touch any thing related to the object execpt remove it from the active symbol. And the same memory location(or handle)