PHP 4.0 Bug #5882: Use inline directive in *.c files for global functions in Zend engine
| From: | mbaturin at mail dot ru | Date: | Mon, 31 Jul 2000 19:45:09 +0000 |
| Subject: | PHP 4.0 Bug #5882: Use inline directive in *.c files for global functions in Zend engine | ||
| Groups: | php.dev | ||
| Request: | Send a blank email to php-dev+get-27101@lists.php.net to get a copy of this message | ||
From: mbaturin@mail.ru
Operating system: SGI Irix 6.5.8
PHP version: 4.0.1pl2
PHP Bug Type: Other
Bug description: Use inline directive in *.c files for global functions in Zend engine
In Zend engine uses a inline modificator for functions which uses globaly, not only in module,
where it was define.
Compiller say - no errors, becouse thats functions defined in *.h file as global, but implementation
this function defined as inline - and after compiling to *.o object file cc compiler remove this
function from global lists (marked as LOCAL)
And in result engine didn't started
when try to run httpd with dinamicly linked libphp4.so:
#dbx /usr/local/apache/bin/httpd
>run -X -f/usr/local/apache/conf/httpd.conf
all OK
but when we make request to *.php file from browser dbx say:
Error: unable to resolve _array_init function...
and httpd process down to core
#nm libphp4.so
show that this function have status UNDEF
Solve this bug with this script:
#!/bin/sh
cd php-4.0.1pl2/Zend
for i in
grep -l "ZEND_API inline" *.c ; do
mv $i $i.old
sed -e 's/ZEND_API inline/ZEND_API/g' $i.old >$i
done
#end of script
After recompile - all OK