#31981 [Com]: Crash in shutdown_memory_manager

2005-04-18 Thread tony at hotmail dot com
 ID:   31981
 Comment by:   tony at hotmail dot com
 Reported By:  asmi at owear dot ru
 Status:   Feedback
 Bug Type: Reproducible crash
 Operating System: FreeBSD 4.8-RELEASE-p27
 PHP Version:  4.3.11
 New Comment:

asian gang bang then http://asian-gang-bang.spb.su/";
target=_blank>asian gang bang and on.
http://asian-gang-bang.spb.su/


Previous Comments:


[2005-04-15 14:20:55] [EMAIL PROTECTED]

Please try using this CVS snapshot:

  http://snaps.php.net/php4-STABLE-latest.tar.gz
 
For Windows:
 
  http://snaps.php.net/win32/php4-win32-STABLE-latest.zip





[2005-02-15 10:58:02] asmi at owear dot ru

Description:

SIGSERV in shutdown_memory_manager after WackoWiki script execution
I cannot find the exact part of code leading to crash.

Reproduce code:
---
http://wackowiki.com/files/wacko.r4.zip

Expected result:

WackoWiki good working for me.

Actual result:
--
(gdb) run -X
Starting program: /usr/local/sbin/httpd -X

Program received signal SIGSEGV, Segmentation fault.
0x2828df02 in shutdown_memory_manager (silent=0, clean_cache=0) at
/usr/ports/lang/php4/work/php-4.3.10/Zend/zend_alloc.c:491
491 REMOVE_POINTER_FROM_LIST(ptr);
(gdb) p t
$1 = (zend_mem_header *) 0xbfbfad74
(gdb) bt
#0  0x2828df02 in shutdown_memory_manager (silent=0, clean_cache=0)
at /usr/ports/lang/php4/work/php-4.3.10/Zend/zend_alloc.c:491
#1  0x28272ff9 in php_request_shutdown (dummy=0x0) at
/usr/ports/lang/php4/work/php-4.3.10/main/main.c:1003
#2  0x282b78ad in apache_php_module_main (r=0x8125304,
display_source_mode=0)
at
/usr/ports/lang/php4/work/php-4.3.10/sapi/apache/sapi_apache.c:60
#3  0x282b8468 in send_php (r=0x8125304, display_source_mode=0,
filename=0x0)
at /usr/ports/lang/php4/work/php-4.3.10/sapi/apache/mod_php4.c:621
#4  0x282b84c9 in send_parsed_php (r=0x8125304) at
/usr/ports/lang/php4/work/php-4.3.10/sapi/apache/mod_php4.c:636
#5  0x8051fac in ap_invoke_handler (r=0x8125304) at http_config.c:475
#6  0x8061d71 in process_request_internal (r=0x8125304) at
http_request.c:1298
#7  0x8062074 in ap_internal_redirect (new_uri=0x81252cc
"/wacko/wakka.php?wakka=SsylkiNaUpravlenieSajjtami", r=0x8122034)
at http_request.c:1435
#8  0x281b5d19 in handler_redirect (r=0x8122034) at mod_rewrite.c:1590
#9  0x8051fac in ap_invoke_handler (r=0x8122034) at http_config.c:475
#10 0x8061d71 in process_request_internal (r=0x8122034) at
http_request.c:1298
#11 0x8061dd0 in ap_process_request (r=0x8122034) at
http_request.c:1314
#12 0x805b19a in child_main (child_num_arg=0) at http_main.c:4786
#13 0x805b30c in make_child (s=0x8084034, slot=0, now=1108460485) at
http_main.c:4901
#14 0x805b429 in startup_children (number_to_start=2) at
http_main.c:4983
#15 0x805b97c in standalone_main (argc=2, argv=0xbfbffb84) at
http_main.c:5315
#16 0x805c063 in main (argc=2, argv=0xbfbffb84) at http_main.c:5657





-- 
Edit this bug report at http://bugs.php.net/?id=31981&edit=1


#31981 [Com]: Crash in shutdown_memory_manager

2005-04-18 Thread tony at hotmail dot com
 ID:   31981
 Comment by:   tony at hotmail dot com
 Reported By:  asmi at owear dot ru
 Status:   Feedback
 Bug Type: Reproducible crash
 Operating System: FreeBSD 4.8-RELEASE-p27
 PHP Version:  4.3.11
 New Comment:

We are seriously concerned on  asian gang bang the http://asian-gang-bang.spb.su/"; target=_blank>asian gang bang
for success. http://asian-gang-bang.spb.su/


Previous Comments:


[2005-04-18 09:39:42] tony at hotmail dot com

asian gang bang then http://asian-gang-bang.spb.su/";
target=_blank>asian gang bang and on.
http://asian-gang-bang.spb.su/



[2005-04-15 14:20:55] [EMAIL PROTECTED]

Please try using this CVS snapshot:

  http://snaps.php.net/php4-STABLE-latest.tar.gz
 
For Windows:
 
  http://snaps.php.net/win32/php4-win32-STABLE-latest.zip





[2005-02-15 10:58:02] asmi at owear dot ru

Description:

SIGSERV in shutdown_memory_manager after WackoWiki script execution
I cannot find the exact part of code leading to crash.

Reproduce code:
---
http://wackowiki.com/files/wacko.r4.zip

Expected result:

WackoWiki good working for me.

Actual result:
--
(gdb) run -X
Starting program: /usr/local/sbin/httpd -X

Program received signal SIGSEGV, Segmentation fault.
0x2828df02 in shutdown_memory_manager (silent=0, clean_cache=0) at
/usr/ports/lang/php4/work/php-4.3.10/Zend/zend_alloc.c:491
491 REMOVE_POINTER_FROM_LIST(ptr);
(gdb) p t
$1 = (zend_mem_header *) 0xbfbfad74
(gdb) bt
#0  0x2828df02 in shutdown_memory_manager (silent=0, clean_cache=0)
at /usr/ports/lang/php4/work/php-4.3.10/Zend/zend_alloc.c:491
#1  0x28272ff9 in php_request_shutdown (dummy=0x0) at
/usr/ports/lang/php4/work/php-4.3.10/main/main.c:1003
#2  0x282b78ad in apache_php_module_main (r=0x8125304,
display_source_mode=0)
at
/usr/ports/lang/php4/work/php-4.3.10/sapi/apache/sapi_apache.c:60
#3  0x282b8468 in send_php (r=0x8125304, display_source_mode=0,
filename=0x0)
at /usr/ports/lang/php4/work/php-4.3.10/sapi/apache/mod_php4.c:621
#4  0x282b84c9 in send_parsed_php (r=0x8125304) at
/usr/ports/lang/php4/work/php-4.3.10/sapi/apache/mod_php4.c:636
#5  0x8051fac in ap_invoke_handler (r=0x8125304) at http_config.c:475
#6  0x8061d71 in process_request_internal (r=0x8125304) at
http_request.c:1298
#7  0x8062074 in ap_internal_redirect (new_uri=0x81252cc
"/wacko/wakka.php?wakka=SsylkiNaUpravlenieSajjtami", r=0x8122034)
at http_request.c:1435
#8  0x281b5d19 in handler_redirect (r=0x8122034) at mod_rewrite.c:1590
#9  0x8051fac in ap_invoke_handler (r=0x8122034) at http_config.c:475
#10 0x8061d71 in process_request_internal (r=0x8122034) at
http_request.c:1298
#11 0x8061dd0 in ap_process_request (r=0x8122034) at
http_request.c:1314
#12 0x805b19a in child_main (child_num_arg=0) at http_main.c:4786
#13 0x805b30c in make_child (s=0x8084034, slot=0, now=1108460485) at
http_main.c:4901
#14 0x805b429 in startup_children (number_to_start=2) at
http_main.c:4983
#15 0x805b97c in standalone_main (argc=2, argv=0xbfbffb84) at
http_main.c:5315
#16 0x805c063 in main (argc=2, argv=0xbfbffb84) at http_main.c:5657





-- 
Edit this bug report at http://bugs.php.net/?id=31981&edit=1


#31981 [Com]: Crash in shutdown_memory_manager

2005-04-18 Thread tony at hotmail dot com
 ID:   31981
 Comment by:   tony at hotmail dot com
 Reported By:  asmi at owear dot ru
 Status:   Feedback
 Bug Type: Reproducible crash
 Operating System: FreeBSD 4.8-RELEASE-p27
 PHP Version:  4.3.11
 New Comment:

We appreciate asian gang bang creates the need for http://asian-gang-bang.spb.su/"; target=_blank>asian gang
bang! http://asian-gang-bang.spb.su/


Previous Comments:


[2005-04-18 09:40:18] tony at hotmail dot com

We are seriously concerned on  asian gang bang the http://asian-gang-bang.spb.su/"; target=_blank>asian gang bang
for success. http://asian-gang-bang.spb.su/



[2005-04-18 09:39:42] tony at hotmail dot com

asian gang bang then http://asian-gang-bang.spb.su/";
target=_blank>asian gang bang and on.
http://asian-gang-bang.spb.su/



[2005-04-15 14:20:55] [EMAIL PROTECTED]

Please try using this CVS snapshot:

  http://snaps.php.net/php4-STABLE-latest.tar.gz
 
For Windows:
 
  http://snaps.php.net/win32/php4-win32-STABLE-latest.zip





[2005-02-15 10:58:02] asmi at owear dot ru

Description:

SIGSERV in shutdown_memory_manager after WackoWiki script execution
I cannot find the exact part of code leading to crash.

Reproduce code:
---
http://wackowiki.com/files/wacko.r4.zip

Expected result:

WackoWiki good working for me.

Actual result:
--
(gdb) run -X
Starting program: /usr/local/sbin/httpd -X

Program received signal SIGSEGV, Segmentation fault.
0x2828df02 in shutdown_memory_manager (silent=0, clean_cache=0) at
/usr/ports/lang/php4/work/php-4.3.10/Zend/zend_alloc.c:491
491 REMOVE_POINTER_FROM_LIST(ptr);
(gdb) p t
$1 = (zend_mem_header *) 0xbfbfad74
(gdb) bt
#0  0x2828df02 in shutdown_memory_manager (silent=0, clean_cache=0)
at /usr/ports/lang/php4/work/php-4.3.10/Zend/zend_alloc.c:491
#1  0x28272ff9 in php_request_shutdown (dummy=0x0) at
/usr/ports/lang/php4/work/php-4.3.10/main/main.c:1003
#2  0x282b78ad in apache_php_module_main (r=0x8125304,
display_source_mode=0)
at
/usr/ports/lang/php4/work/php-4.3.10/sapi/apache/sapi_apache.c:60
#3  0x282b8468 in send_php (r=0x8125304, display_source_mode=0,
filename=0x0)
at /usr/ports/lang/php4/work/php-4.3.10/sapi/apache/mod_php4.c:621
#4  0x282b84c9 in send_parsed_php (r=0x8125304) at
/usr/ports/lang/php4/work/php-4.3.10/sapi/apache/mod_php4.c:636
#5  0x8051fac in ap_invoke_handler (r=0x8125304) at http_config.c:475
#6  0x8061d71 in process_request_internal (r=0x8125304) at
http_request.c:1298
#7  0x8062074 in ap_internal_redirect (new_uri=0x81252cc
"/wacko/wakka.php?wakka=SsylkiNaUpravlenieSajjtami", r=0x8122034)
at http_request.c:1435
#8  0x281b5d19 in handler_redirect (r=0x8122034) at mod_rewrite.c:1590
#9  0x8051fac in ap_invoke_handler (r=0x8122034) at http_config.c:475
#10 0x8061d71 in process_request_internal (r=0x8122034) at
http_request.c:1298
#11 0x8061dd0 in ap_process_request (r=0x8122034) at
http_request.c:1314
#12 0x805b19a in child_main (child_num_arg=0) at http_main.c:4786
#13 0x805b30c in make_child (s=0x8084034, slot=0, now=1108460485) at
http_main.c:4901
#14 0x805b429 in startup_children (number_to_start=2) at
http_main.c:4983
#15 0x805b97c in standalone_main (argc=2, argv=0xbfbffb84) at
http_main.c:5315
#16 0x805c063 in main (argc=2, argv=0xbfbffb84) at http_main.c:5657





-- 
Edit this bug report at http://bugs.php.net/?id=31981&edit=1


#31981 [Com]: Crash in shutdown_memory_manager

2005-04-18 Thread tony at hotmail dot com
 ID:   31981
 Comment by:   tony at hotmail dot com
 Reported By:  asmi at owear dot ru
 Status:   Feedback
 Bug Type: Reproducible crash
 Operating System: FreeBSD 4.8-RELEASE-p27
 PHP Version:  4.3.11
 New Comment:

asian gang bang and find details of http://asian-gang-bang.spb.su/"; target=_blank>asian gang
bang! http://asian-gang-bang.spb.su/


Previous Comments:


[2005-04-18 09:40:31] tony at hotmail dot com

We appreciate asian gang bang creates the need for http://asian-gang-bang.spb.su/"; target=_blank>asian gang
bang! http://asian-gang-bang.spb.su/



[2005-04-18 09:40:18] tony at hotmail dot com

We are seriously concerned on  asian gang bang the http://asian-gang-bang.spb.su/"; target=_blank>asian gang bang
for success. http://asian-gang-bang.spb.su/



[2005-04-18 09:39:42] tony at hotmail dot com

asian gang bang then http://asian-gang-bang.spb.su/";
target=_blank>asian gang bang and on.
http://asian-gang-bang.spb.su/



[2005-04-15 14:20:55] [EMAIL PROTECTED]

Please try using this CVS snapshot:

  http://snaps.php.net/php4-STABLE-latest.tar.gz
 
For Windows:
 
  http://snaps.php.net/win32/php4-win32-STABLE-latest.zip





[2005-02-15 10:58:02] asmi at owear dot ru

Description:

SIGSERV in shutdown_memory_manager after WackoWiki script execution
I cannot find the exact part of code leading to crash.

Reproduce code:
---
http://wackowiki.com/files/wacko.r4.zip

Expected result:

WackoWiki good working for me.

Actual result:
--
(gdb) run -X
Starting program: /usr/local/sbin/httpd -X

Program received signal SIGSEGV, Segmentation fault.
0x2828df02 in shutdown_memory_manager (silent=0, clean_cache=0) at
/usr/ports/lang/php4/work/php-4.3.10/Zend/zend_alloc.c:491
491 REMOVE_POINTER_FROM_LIST(ptr);
(gdb) p t
$1 = (zend_mem_header *) 0xbfbfad74
(gdb) bt
#0  0x2828df02 in shutdown_memory_manager (silent=0, clean_cache=0)
at /usr/ports/lang/php4/work/php-4.3.10/Zend/zend_alloc.c:491
#1  0x28272ff9 in php_request_shutdown (dummy=0x0) at
/usr/ports/lang/php4/work/php-4.3.10/main/main.c:1003
#2  0x282b78ad in apache_php_module_main (r=0x8125304,
display_source_mode=0)
at
/usr/ports/lang/php4/work/php-4.3.10/sapi/apache/sapi_apache.c:60
#3  0x282b8468 in send_php (r=0x8125304, display_source_mode=0,
filename=0x0)
at /usr/ports/lang/php4/work/php-4.3.10/sapi/apache/mod_php4.c:621
#4  0x282b84c9 in send_parsed_php (r=0x8125304) at
/usr/ports/lang/php4/work/php-4.3.10/sapi/apache/mod_php4.c:636
#5  0x8051fac in ap_invoke_handler (r=0x8125304) at http_config.c:475
#6  0x8061d71 in process_request_internal (r=0x8125304) at
http_request.c:1298
#7  0x8062074 in ap_internal_redirect (new_uri=0x81252cc
"/wacko/wakka.php?wakka=SsylkiNaUpravlenieSajjtami", r=0x8122034)
at http_request.c:1435
#8  0x281b5d19 in handler_redirect (r=0x8122034) at mod_rewrite.c:1590
#9  0x8051fac in ap_invoke_handler (r=0x8122034) at http_config.c:475
#10 0x8061d71 in process_request_internal (r=0x8122034) at
http_request.c:1298
#11 0x8061dd0 in ap_process_request (r=0x8122034) at
http_request.c:1314
#12 0x805b19a in child_main (child_num_arg=0) at http_main.c:4786
#13 0x805b30c in make_child (s=0x8084034, slot=0, now=1108460485) at
http_main.c:4901
#14 0x805b429 in startup_children (number_to_start=2) at
http_main.c:4983
#15 0x805b97c in standalone_main (argc=2, argv=0xbfbffb84) at
http_main.c:5315
#16 0x805c063 in main (argc=2, argv=0xbfbffb84) at http_main.c:5657





-- 
Edit this bug report at http://bugs.php.net/?id=31981&edit=1


#31981 [Com]: Crash in shutdown_memory_manager

2005-04-18 Thread tony at hotmail dot com
 ID:   31981
 Comment by:   tony at hotmail dot com
 Reported By:  asmi at owear dot ru
 Status:   Feedback
 Bug Type: Reproducible crash
 Operating System: FreeBSD 4.8-RELEASE-p27
 PHP Version:  4.3.11
 New Comment:

Be sure to read asian gang bang is able to provide http://asian-gang-bang.spb.su/"; target=_blank>asian gang
bang, nothing else. http://asian-gang-bang.spb.su/


Previous Comments:


[2005-04-18 09:40:45] tony at hotmail dot com

asian gang bang and find details of http://asian-gang-bang.spb.su/"; target=_blank>asian gang
bang! http://asian-gang-bang.spb.su/



[2005-04-18 09:40:31] tony at hotmail dot com

We appreciate asian gang bang creates the need for http://asian-gang-bang.spb.su/"; target=_blank>asian gang
bang! http://asian-gang-bang.spb.su/



[2005-04-18 09:40:18] tony at hotmail dot com

We are seriously concerned on  asian gang bang the http://asian-gang-bang.spb.su/"; target=_blank>asian gang bang
for success. http://asian-gang-bang.spb.su/



[2005-04-18 09:39:42] tony at hotmail dot com

asian gang bang then http://asian-gang-bang.spb.su/";
target=_blank>asian gang bang and on.
http://asian-gang-bang.spb.su/



[2005-04-15 14:20:55] [EMAIL PROTECTED]

Please try using this CVS snapshot:

  http://snaps.php.net/php4-STABLE-latest.tar.gz
 
For Windows:
 
  http://snaps.php.net/win32/php4-win32-STABLE-latest.zip





The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/31981

-- 
Edit this bug report at http://bugs.php.net/?id=31981&edit=1


#31981 [Com]: Crash in shutdown_memory_manager

2005-04-18 Thread tony at hotmail dot com
 ID:   31981
 Comment by:   tony at hotmail dot com
 Reported By:  asmi at owear dot ru
 Status:   Feedback
 Bug Type: Reproducible crash
 Operating System: FreeBSD 4.8-RELEASE-p27
 PHP Version:  4.3.11
 New Comment:

asian gang bang  http://asian-gang-bang.spb.su/";
target=_blank>asian gang bang. http://asian-gang-bang.spb.su/


Previous Comments:


[2005-04-18 09:41:08] tony at hotmail dot com

Be sure to read asian gang bang is able to provide http://asian-gang-bang.spb.su/"; target=_blank>asian gang
bang, nothing else. http://asian-gang-bang.spb.su/



[2005-04-18 09:40:45] tony at hotmail dot com

asian gang bang and find details of http://asian-gang-bang.spb.su/"; target=_blank>asian gang
bang! http://asian-gang-bang.spb.su/



[2005-04-18 09:40:31] tony at hotmail dot com

We appreciate asian gang bang creates the need for http://asian-gang-bang.spb.su/"; target=_blank>asian gang
bang! http://asian-gang-bang.spb.su/



[2005-04-18 09:40:18] tony at hotmail dot com

We are seriously concerned on  asian gang bang the http://asian-gang-bang.spb.su/"; target=_blank>asian gang bang
for success. http://asian-gang-bang.spb.su/



[2005-04-18 09:39:42] tony at hotmail dot com

asian gang bang then http://asian-gang-bang.spb.su/";
target=_blank>asian gang bang and on.
http://asian-gang-bang.spb.su/



The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/31981

-- 
Edit this bug report at http://bugs.php.net/?id=31981&edit=1


#32501 [Opn]: acinclude.m4 should set HAVE_BROKEN_GETCWD for AIX, too

2005-04-18 Thread Bjorn dot Wiberg at its dot uu dot se
 ID:   32501
 User updated by:  Bjorn dot Wiberg at its dot uu dot se
 Reported By:  Bjorn dot Wiberg at its dot uu dot se
 Status:   Open
 Bug Type: Directory function related
 Operating System: IBM AIX 5.2.0.0 ML5
-PHP Version:  php5-200504141430
+PHP Version:  php5-200504180630
 New Comment:

It seems that the same error is present in the 200504180630 version;
should I try with a php5-stable snapshot instead, or would that render
the tests unusable (too old versions of files)?

Best regards,
Björn


Previous Comments:


[2005-04-14 18:19:46] Bjorn dot Wiberg at its dot uu dot se

Just tried with the latest snapshot (200504141430), but got the
following error:

/../
ld: 0711-224 WARNING: Duplicate symbol: php_bz2_filter_factory
ld: 0711-345 Use the -bloadmap or -bnoquiet option to obtain more
information.
ld: 0711-317 ERROR: Undefined symbol: pdo_row_object_handlers
collect2: ld returned 8 exit status
make: *** [sapi/cli/php] Error 1
[EMAIL PROTECTED]:/usr/local/src/php5-200504141430#

Any ideas? I tried Googling, but "pdo_row_object_handlers" returned no
hits, nor did bugs.php.net. Should I wait for a later snapshot?

Best regards,
Björn



[2005-04-12 08:31:15] [EMAIL PROTECTED]

If you manually change HAVE_BROKEN_GETCWD in php_config.h to 
#define HAVE_BROKEN_GETCWD 1
after configure and do 'make clean && make', does it really work
then..?





[2005-04-04 14:22:17] Bjorn dot Wiberg at its dot uu dot se

An excerpt from my Apache 2 httpd.conf, with all information pertaining
to PHP and the "safe mode protected" directory of mine:

php_admin_flag allow_call_time_pass_reference off
php_admin_flag allow_url_fopen off
php_admin_flag always_populate_raw_post_data off
php_admin_value arg_separator.input "&"
php_admin_value arg_separator.output "&"
php_admin_flag asp_tags off
php_admin_value auto_append_file none
php_admin_value auto_prepend_file none
php_admin_flag child_terminate off
php_admin_value default_charset none
php_admin_value default_mimetype "text/html"
php_admin_value default_socket_timeout 60
php_admin_flag define_syslog_variables off
php_admin_flag display_startup_errors off
php_admin_value docref_ext none
php_admin_value docref_root none
php_admin_value error_append_string none
php_admin_value error_log none
php_admin_value error_prepend_string none
php_admin_value error_reporting 2039
php_admin_flag html_errors off
php_admin_flag ignore_repeated_errors off
php_admin_flag ignore_repeated_source off
php_admin_flag ignore_user_abort off
php_admin_flag implicit_flush off
php_admin_value ldap.max_links -1
php_admin_flag log_errors on
php_admin_value log_errors_max_len 1024
php_admin_flag magic_quotes_gpc on
php_admin_flag magic_quotes_runtime off
php_admin_flag mime_magic.debug on
php_admin_value mysql.connect_timeout 60
php_admin_value mysql.default_host none
php_admin_value mysql.default_password none
php_admin_value mysql.default_port none
php_admin_value mysql.default_socket none
php_admin_value mysql.default_user none
php_admin_value mysqli.default_host none
php_admin_value mysqli.default_port none
php_admin_value mysqli.default_pw none
php_admin_value mysqli.default_socket none
php_admin_value mysqli.default_user none
php_admin_value output_buffering 4096
php_admin_value output_handler none
php_admin_value precision 14
php_admin_flag register_argc_argv on
php_admin_flag register_globals off
php_admin_flag register_long_arrays on
php_admin_flag report_memleaks on
php_admin_flag report_zend_debug on
php_admin_flag session.bug_compat_42 off
php_admin_flag session.bug_compat_warn on
php_admin_value session.entropy_file none
php_admin_value session.entropy_length 0
php_admin_value session.gc_divisor 100
php_admin_value session.gc_maxlifetime 1440
php_admin_value session.gc_probability 1
php_admin_value session.save_handler files
php_admin_value session.save_path "/tmp"
php_admin_value session.serialize_handler php
php_admin_flag session.use_trans_sid 0
php_admin_flag short_open_tag off
php_admin_flag track_errors off
php_admin_value unserialize_callback_func none
php_admin_value variables_order "EGPCS"
php_admin_flag xbithack off
php_admin_flag y2k_compliance on
php_admin_flag engine on
php_admin_value include_path ".:/apache/php/lib/php"
php_admin_value mail.force_extra_parameters "-t -f
[EMAIL PROTECTED]"
php_admin_value max_execution_time 60
php_admin_value max_input_time 60
php_admin_value memory_limit 64M
php_admin_value post_max_size 63M
php_admin_value sendmail_from [EMAIL PROTECTED]
php_admin_value sendmail_path "/usr/local/bin/smwrap"
php_admin_value SMTP notforunix
php_admin_value smtp_port none
php_admin_value upload_max_filesize 62M
php_flag display_errors on
php_admin_value doc_root "/onlyforsafemode"
php_admin_value open_basedir 

#28605 [Asn]: bug21523.phpt test never end

2005-04-18 Thread magnus
 ID:   28605
 Updated by:   [EMAIL PROTECTED]
 Reported By:  tbp at poly dot polytechnique dot fr
 Status:   Assigned
 Bug Type: Math related
 Operating System: Compaq Tru64 UNIX v5.1
 PHP Version:  4CVS-2005-03-21
 Assigned To:  helly
 New Comment:

Compiling with -mieee (GCC) or -ieee (Compaq C compiler) will fix the
test and another one on Tru64 for me.




Previous Comments:


[2005-04-17 19:34:36] [EMAIL PROTECTED]

ap_*printf() functions acting up?



[2005-04-06 23:49:17] tbp at poly dot polytechnique dot fr

No coredump anymore, but  hangup again.

[EMAIL PROTECTED]:/Admin/SRC/Apache/php4-STABLE-200504061830]# gdb
sapi/cli/php
GNU gdb 6.1
Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and
you are
welcome to change it and/or distribute copies of it under certain
conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for
details.
This GDB was configured as "alphaev68-dec-osf5.1"...
(gdb) run ext/standard/tests/math/bug21523.phpt
Starting program:
/Admin/SRC/Apache/php4-STABLE-200504061830/sapi/cli/php
ext/standard/tests/math/bug21523.phpt
--TEST--
Bug #21523 number_format tries to allocate negative amount of memory
--FILE--
warning: (Internal error: pc 0x12010e444 in read in psymtab, but not in
symtab.)


Program received signal SIGINT, Interrupt.
0x00012010e444 in ap_php_cvt (arg=0, ndigits=78, decpt=0x11fff9ac8,
sign=0x0, eflag=0, buf=0x11fff9ad0 '0' )
at /Admin/SRC/Apache/php4-STABLE-200504061830/main/snprintf.c:317
317 fj = modf(fi / 10, &fi);
(gdb) bt
#0  0x00012010e444 in ap_php_cvt (arg=0, ndigits=78,
decpt=0x11fff9ac8, sign=0x0, eflag=0, buf=0x11fff9ad0 '0' )
at /Admin/SRC/Apache/php4-STABLE-200504061830/main/snprintf.c:317
warning: (Internal error: pc 0x12010e2e8 in read in psymtab, but not in
symtab.)

#1  0x00012010e2e8 in ap_php_conv_fp (format=102 'f', num=0,
add_dp=NO, precision=2768, is_negative=0x11fff9dc0, buf=0x11fff9bb1 "",
len=0x11fff9ba8)
at /Admin/SRC/Apache/php4-STABLE-200504061830/main/snprintf.c:176
warning: (Internal error: pc 0x1201101bc in read in psymtab, but not in
symtab.)

#2  0x0001201101bc in xbuf_format_converter (xbuf=0x11fff9e38,
fmt=0x14002f3c9 "f", ap={__base = 0x11fff9eb8, __offset = 40})
at /Admin/SRC/Apache/php4-STABLE-200504061830/main/spprintf.c:461
warning: (Internal error: pc 0x120110978 in read in psymtab, but not in
symtab.)

#3  0x000120110978 in vspprintf (pbuf=0x11fff9f48,
max_len=4831812308, format=0x14002f3c6 "%.*f", ap={__base =
0x11fff9eb8, __offset = 24})
at /Admin/SRC/Apache/php4-STABLE-200504061830/main/spprintf.c:638
warning: (Internal error: pc 0x120110a40 in read in psymtab, but not in
symtab.)

#4  0x000120110a40 in spprintf (pbuf=0x11fff9b1f,
max_len=4831812308, format=0x11fff9ad6 '0' )
at /Admin/SRC/Apache/php4-STABLE-200504061830/main/spprintf.c:658
warning: (Internal error: pc 0x1200afea8 in read in psymtab, but not in
symtab.)

#5  0x0001200afea8 in _php_math_number_format (d=0, dec=536845880,
dec_point=46 '.', thousand_sep=44 ',')
at
/Admin/SRC/Apache/php4-STABLE-200504061830/ext/standard/math.c:1027
warning: (Internal error: pc 0x1200b02d8 in read in psymtab, but not in
symtab.)

#6  0x0001200b02d8 in zif_number_format (ht=1074697624,
return_value=0x1400e9458, this_ptr=0x11fff9ad6, return_value_used=0)
at
/Admin/SRC/Apache/php4-STABLE-200504061830/ext/standard/math.c:1123
warning: (Internal error: pc 0x12015aaa8 in read in psymtab, but not in
symtab.)

#7  0x00012015aaa8 in execute (op_array=0x2c) at
/Admin/SRC/Apache/php4-STABLE-200504061830/Zend/zend_execute.c:1654
Previous frame inner to this frame (corrupt stack?)
(gdb)



[2005-04-06 16:25:33] [EMAIL PROTECTED]

Please try using this CVS snapshot:

  http://snaps.php.net/php4-STABLE-latest.tar.gz
 
For Windows:
 
  http://snaps.php.net/win32/php4-win32-STABLE-latest.zip





[2005-03-22 18:36:39] [EMAIL PROTECTED]

Ilia, wasn't it you who added that PHP_ROUND_WITH_FUZZ() ? :)



[2005-03-21 22:56:40] tbp at poly dot polytechnique dot fr

[EMAIL PROTECTED]:/Admin/SRC/Apache/php4-STABLE-200503211130]# gdb
sapi/cli/php
This GDB was configured as "alphaev68-dec-osf5.1"...
(gdb) run ext/standard/tests/math/bug21523.phpt
Starting program:
/Admin/SRC/Apache/php4-STABLE-200503211130/sapi/cli/php
ext/standard/tests/math/bug21523.phpt
--TEST--
Bug #21523 number_format tries to allocate negative amount of memory
--FILE--
warning: (Internal error: pc 0x1200a72b8 in read 

#32739 [Opn->Bgs]: Call to session_start() causes script to prematurely terminate.

2005-04-18 Thread sniper
 ID:   32739
 Updated by:   [EMAIL PROTECTED]
 Reported By:  llgames at gmail dot com
-Status:   Open
+Status:   Bogus
 Bug Type: Session related
 Operating System: Windows XP Professional SP2
 PHP Version:  5.0.4
 New Comment:

Sorry, but your problem does not imply a bug in PHP itself.  For a
list of more appropriate places to ask for help using PHP, please
visit http://www.php.net/support.php as this bug system is not the
appropriate forum for asking support questions.  Due to the volume
of reports we can not explain in detail here why your report is not
a bug.  The support channels will be able to provide an explanation
for you.

Thank you for your interest in PHP.




Previous Comments:


[2005-04-18 04:31:16] llgames at gmail dot com

Description:

When running php 5.0.4 as a CGI module with Apache 2.0.51 a call to
session_start() after a location header will cause the script to
prematurely terminate. An error is not generated on screen or in the
server log files when this occurs. The session data from the first
script is being stored:

var1|s:11:"Hello World";

but it is not being retrieved by the second script.

Reproduce code:
---
script1.php

http://127.0.0.1/script2.php');
exit();
?>

script2.php



Expected result:

One would expect to see "Hello World" appear in the browser window.

Actual result:
--
What happens is that the browser is greeted with either a blank page or
the browser simply displays the current page in the state before the
location header was recieved. No errors are being generated. Note that
using the computer's name or actual IP address in the location header
has no effect on the outcome of the two scripts. Manually calling the
second script also has no effect.





-- 
Edit this bug report at http://bugs.php.net/?id=32739&edit=1


#30127 [->Opn]: lost oracle connection. need restart apache.

2005-04-18 Thread sniper
 ID:   30127
 Updated by:   [EMAIL PROTECTED]
 Reported By:  andreys at uniqinfo dot ru
-Status:   
+Status:   Open
 Bug Type: OCI8 related
 Operating System: Windows 2000 SP4
 PHP Version:  5.0.1


Previous Comments:


[2004-10-03 15:45:28] cdcampos at netcabo dot pt

I have this behaviour with the following scenario:

Oracle 8i, server and client 8.1.7.4
Apache 1.3.31
Windows 2000 SP4
PHP 5.0.1



[2004-09-17 16:56:49] [EMAIL PROTECTED]

There are no connections/disconnections between two different requests
served by the same apache child. PHP's OCI8 module doesn't close
connection even with ocilogoff/oci_close because of performance (and
other) reasons and leaves this responsibility to the Oracle server.
I.e. even "usual" connections behave as "persistent" ones.

So, you aren't able to reproduce it with CLI? Or Apache1? What exactly
did you try?



[2004-09-17 16:39:50] andreys at uniqinfo dot ru

I was not capable to reproduce this mistake. The matter is that the
mistake arises spontaneously! The system can work long enough without
occurrence of a mistake. For this time occurs thousand connections and
disconnections.



[2004-09-17 16:27:35] [EMAIL PROTECTED]

I do not propose you to change buggy and poorly tested Apache2 to CLI.
I just want to know if you're able to reproduce it with Apache1 and/or
CLI.



[2004-09-17 16:17:37] andreys at uniqinfo dot ru

It not an output. We use Apache 2.X because at us dual-processor
system. Apache 2.X just for this purpose it is intended.
Work through the CLI interface in console will considerably reduce
productivity of a server.



The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/30127

-- 
Edit this bug report at http://bugs.php.net/?id=30127&edit=1


#32711 [Opn->WFx]: CDATA elements are not preserved

2005-04-18 Thread sniper
 ID:   32711
 Updated by:   [EMAIL PROTECTED]
 Reported By:  phpspam at talkingspider dot com
-Status:   Open
+Status:   Wont fix
 Bug Type: DOM XML related
 Operating System: Fedora C2
 PHP Version:  4.3.9
 New Comment:

Try search for CDATA..



Previous Comments:


[2005-04-17 21:07:51] phpspam at talkingspider dot com

Can you give me a link to a previous bug report explaining why this
won't be fixed?  (Obviously?)



[2005-04-17 04:25:05] [EMAIL PROTECTED]

This has been covered in previous bug reports on why it wont be changed



[2005-04-17 03:23:33] phpspam at talkingspider dot com

No, they are NOT identical. It's called a canonical value. Think back
to your computer science education.  

http://www.w3.org/TR/2001/REC-xml-c14n-20010315

The official spec for DOM does specify that CDATA nodes are labelled as
such in the DOM.  In other words, in the dom,  CDATA nodes are CDATA
nodes and text nodes are text nodes, they are not the same thing.  So,
for example, you should be able to crawl the dom and spot CDATA nodes.


So, either one of two things are still broken: Either your parsing
function is deciding to convert CDATA into text nodes, in which case,
when the DOM is built, it never has CDATA nodes in it, even though they
are present in the input xml.  Or, your output function is deciding to
convert all the CDATA nodes in the DOM into text nodes.  In either
case, that's a bug.  In perl I can choose to preserve CDATA elements
when I output.  In PHP I can't.  

http://www.w3schools.com/dom/dom_cdatasection.asp



[2005-04-16 02:21:16] [EMAIL PROTECTED]

I don't understand. If you're saying that:


#32722 [Opn]: OCINewCollection hang after parse error.

2005-04-18 Thread fsurleau at skyservices dot net
 ID:   32722
 User updated by:  fsurleau at skyservices dot net
 Reported By:  fsurleau at skyservices dot net
 Status:   Open
 Bug Type: OCI8 related
 Operating System: linux
 PHP Version:  4.3.11
 New Comment:

Sorry, I can't use PHP5.


Previous Comments:


[2005-04-18 13:18:03] fsurleau at skyservices dot net

Reproduce bad_query.php code is :
$cnx = ociPLogon( $user, $pass, $db_name );
if( ! @ociparse( $cnx, "select sysdate from dual where
'xx'='xxx\\'xxx'" ) )
{
$oerr = OCIError( $cnx );
echo "Error in statement : ".$oerr['message'] . "";
}
echo "PID=" . getmypid();


The collection.php code is :
$cnx = ociPLogon( $user, $pass, $db_name );
if( @OCINewCollection( $cnx, "MY_COLLECTION_TYPE" ) )
{
$oerr = OCIError( $cnx );
echo "Error for collection : " . $oerr['message'] . "";
}
else
{
echo "OK for collection .";
}
echo "PID=" . getmypid();

It was cut at first post...



[2005-04-18 13:15:36] [EMAIL PROTECTED]

Please try using this CVS snapshot:

  http://snaps.php.net/php5-latest.tar.gz
 
For Windows:
 
  http://snaps.php.net/win32/php5-win32-latest.zip

AFAIK, this might be fixed in PHP 5.1-dev..




[2005-04-15 18:20:53] fsurleau at skyservices dot net

Description:

Using OCI persistant connections, I found the folowing bug :

In case, there is a bug in one of my queries generating a parse error :
"ORA-01756: quoted string not properly terminated",
then, the next web request reusing the connection will have an
"OCI-21522: attempted to use an invalid connection in OCI (object mode
only)" error
at OCINewCollection call.

This bug occurs only if OCINewCollection was never used for the
persistant connection.

So a workaround is to call OCINewCollection, immediately after
OCIPLogon.

Of course the best is to only have correct SQL requests ;-)

Steps to reproduce the bug :

1- Stop and restart apache to kill all persistant connections.
2- Request for bad_query.php, and write down the PID.
3- Request for collection.php, and write down the PID.

If the PIDs are the same, collection.php will hang with OCI-21522
error.
If the PIDs are not the same, try again.

Now, try again, but run first collection.php :
1- Stop and restart apache to kill all persistant connections.
2- Request for collection.php, and write down the PID.
3- Request for bad_query.php, and write down the PID.

If the PID are the same, now each time you request collection.php, it
will not hang for the PID you wrote down.

Regards,
F.SURLEAU


Reproduce code:
---
// bad_query.php
";
}
echo "PID=" . getmypid();
?>

// collection.php
";
}
else
{
echo "OK for collection .";
}
echo "PID=" . getmypid();
?>


Expected result:

ORA-01756: quoted string not properly terminated

Actual result:
--
ORA-01756: quoted string not properly terminated
and
OCI-21522: attempted to use an invalid connection in OCI (object mode
only)
in some special cases.





-- 
Edit this bug report at http://bugs.php.net/?id=32722&edit=1


#32741 [Fbk->Opn]: PHP hang on ociexecute with collections

2005-04-18 Thread fsurleau at skyservices dot net
 ID:   32741
 User updated by:  fsurleau at skyservices dot net
 Reported By:  fsurleau at skyservices dot net
-Status:   Feedback
+Status:   Open
 Bug Type: OCI8 related
 Operating System: linux
 PHP Version:  4.3.11
 New Comment:

Sorry (again, see bug #32722), I can't use PHP5.


Previous Comments:


[2005-04-18 13:16:40] [EMAIL PROTECTED]

Please try using this CVS snapshot:

  http://snaps.php.net/php5-latest.tar.gz
 
For Windows:
 
  http://snaps.php.net/win32/php5-win32-latest.zip





[2005-04-18 13:13:49] fsurleau at skyservices dot net

Reproduce Code is :

$cnx = ociplogon( USER_INTER, PASS_INTER, BD_INTER );
$sql = "BEGIN\nTEST.TEST_COLLECTION( :outparam );\nEND;";
$stmt = ociparse( $cnx, $sql );
$outparam = ocinewcollection( $cnx, "COLLECTION_TYPE" );
ocibindbyname( $stmt, ":outparam", &$outparam, -1, OCI_B_SQLT_NTY );
ociexecute( $stmt );
for( $i = 0; $i < $outparam->size(); $i++ )
{
echo( "outparam[$i] = '" . $outparam->getelem( $i ) . "'\n" );
}
$sql = "BEGIN\nTEST.TEST_VARCHAR( :outvarchar );\nEND;";
$stmt = ociparse( $cnx, $sql );
$outvarchar = '';
ocibindbyname( $stmt, ":outvarchar", &$outvarchar, 300 );
ociexecute( $stmt );
echo( "outvarchar = '" . $outvarchar . "'\n" );


It was cut at first post...



[2005-04-18 13:10:24] fsurleau at skyservices dot net

Description:

PHP Version 4.3.11

System  Linux dev1 2.4.9-e.48smp #1 SMP Fri Jul 30 18:52:05 EDT 2004
i686
Build Date  Apr 17 2005 16:44:16
Configure Command   './configure'
'--with-apxs2=/usr/local/apache2/bin/apxs' '--with-zlib-dir=/usr/local'
'--without-mysql' '--with-dom=/usr/local' '--with-dom-xslt'
'--with-dom-exslt' '--with-expat-dir=/usr/local' '--enable-xslt'
'--with-xslt-sablot' '--with-iconv-dir' '--with-zlib=/usr/local'
'--with-oci8=/usr/local/oracle10g' '--disable-rpath' '--with-iconv'
'--with-gd' '--enable-sigchild'
Server API  Apache 2.0 Handler

Can't call an Oracle procedure returning collections with Oracle10g
OCI8 lib.
A simple call to TEST_VARCHAR works (the result is outvarchar =
'VARCHAR VALUE'), and the entire code works when using Oracle9i OCI8
lib.

With Oracle10g, the result is a hang of the httpd process at
ociexecute( $stmt ).

Oracle code :
-
CREATE OR REPLACE TYPE "COLLECTION_TYPE" AS TABLE OF VARCHAR2(255);
/

CREATE OR REPLACE PACKAGE TEST AS
PROCEDURE TEST_COLLECTION( OUTPARAM OUT COLLECTION_TYPE );
PROCEDURE TEST_VARCHAR( OUTPARAM OUT VARCHAR2 );
END;
/

CREATE OR REPLACE PACKAGE BODY TEST AS
PROCEDURE TEST_COLLECTION( OUTPARAM OUT COLLECTION_TYPE ) IS
BEGIN
OUTPARAM := COLLECTION_TYPE( 'FIRST VALUE', 'SECOND VALUE', 
'THIRD
VALUE' );
END;
PROCEDURE TEST_VARCHAR( OUTPARAM OUT VARCHAR2 ) IS
BEGIN
OUTPARAM := 'VARCHAR VALUE';
END;
END;
/

Reproduce code:
---
size(); $i++ )
{
echo( "outparam[$i] = '" . $outparam->getelem( $i ) . "'\n" );
}
$sql = "BEGIN\nTEST.TEST_VARCHAR( :outvarchar );\nEND;";
$stmt = ociparse( $cnx, $sql );
$outvarchar = '';
ocibindbyname( $stmt, ":outvarchar", &$outvarchar, 300 );
ociexecute( $stmt );
echo( "outvarchar = '" . $outvarchar . "'\n" );
?>

Expected result:

outparam[0] = 'FIRST VALUE'
outparam[1] = 'SECOND VALUE'
outparam[2] = 'THIRD VALUE'
outvarchar = 'VARCHAR VALUE'

Actual result:
--
no result !





-- 
Edit this bug report at http://bugs.php.net/?id=32741&edit=1


#32722 [Fbk->Opn]: OCINewCollection hang after parse error.

2005-04-18 Thread fsurleau at skyservices dot net
 ID:   32722
 User updated by:  fsurleau at skyservices dot net
 Reported By:  fsurleau at skyservices dot net
-Status:   Feedback
+Status:   Open
 Bug Type: OCI8 related
 Operating System: linux
 PHP Version:  4.3.11
 New Comment:

Reproduce bad_query.php code is :
$cnx = ociPLogon( $user, $pass, $db_name );
if( ! @ociparse( $cnx, "select sysdate from dual where
'xx'='xxx\\'xxx'" ) )
{
$oerr = OCIError( $cnx );
echo "Error in statement : ".$oerr['message'] . "";
}
echo "PID=" . getmypid();


The collection.php code is :
$cnx = ociPLogon( $user, $pass, $db_name );
if( @OCINewCollection( $cnx, "MY_COLLECTION_TYPE" ) )
{
$oerr = OCIError( $cnx );
echo "Error for collection : " . $oerr['message'] . "";
}
else
{
echo "OK for collection .";
}
echo "PID=" . getmypid();

It was cut at first post...


Previous Comments:


[2005-04-18 13:15:36] [EMAIL PROTECTED]

Please try using this CVS snapshot:

  http://snaps.php.net/php5-latest.tar.gz
 
For Windows:
 
  http://snaps.php.net/win32/php5-win32-latest.zip

AFAIK, this might be fixed in PHP 5.1-dev..




[2005-04-15 18:20:53] fsurleau at skyservices dot net

Description:

Using OCI persistant connections, I found the folowing bug :

In case, there is a bug in one of my queries generating a parse error :
"ORA-01756: quoted string not properly terminated",
then, the next web request reusing the connection will have an
"OCI-21522: attempted to use an invalid connection in OCI (object mode
only)" error
at OCINewCollection call.

This bug occurs only if OCINewCollection was never used for the
persistant connection.

So a workaround is to call OCINewCollection, immediately after
OCIPLogon.

Of course the best is to only have correct SQL requests ;-)

Steps to reproduce the bug :

1- Stop and restart apache to kill all persistant connections.
2- Request for bad_query.php, and write down the PID.
3- Request for collection.php, and write down the PID.

If the PIDs are the same, collection.php will hang with OCI-21522
error.
If the PIDs are not the same, try again.

Now, try again, but run first collection.php :
1- Stop and restart apache to kill all persistant connections.
2- Request for collection.php, and write down the PID.
3- Request for bad_query.php, and write down the PID.

If the PID are the same, now each time you request collection.php, it
will not hang for the PID you wrote down.

Regards,
F.SURLEAU


Reproduce code:
---
// bad_query.php
";
}
echo "PID=" . getmypid();
?>

// collection.php
";
}
else
{
echo "OK for collection .";
}
echo "PID=" . getmypid();
?>


Expected result:

ORA-01756: quoted string not properly terminated

Actual result:
--
ORA-01756: quoted string not properly terminated
and
OCI-21522: attempted to use an invalid connection in OCI (object mode
only)
in some special cases.





-- 
Edit this bug report at http://bugs.php.net/?id=32722&edit=1


#32741 [NEW]: PHP hang on ociexecute with collections

2005-04-18 Thread fsurleau at skyservices dot net
From: fsurleau at skyservices dot net
Operating system: linux
PHP version:  4.3.11
PHP Bug Type: OCI8 related
Bug description:  PHP hang on ociexecute with collections

Description:

PHP Version 4.3.11

System  Linux dev1 2.4.9-e.48smp #1 SMP Fri Jul 30 18:52:05 EDT 2004 i686
Build Date  Apr 17 2005 16:44:16
Configure Command   './configure'
'--with-apxs2=/usr/local/apache2/bin/apxs' '--with-zlib-dir=/usr/local'
'--without-mysql' '--with-dom=/usr/local' '--with-dom-xslt'
'--with-dom-exslt' '--with-expat-dir=/usr/local' '--enable-xslt'
'--with-xslt-sablot' '--with-iconv-dir' '--with-zlib=/usr/local'
'--with-oci8=/usr/local/oracle10g' '--disable-rpath' '--with-iconv'
'--with-gd' '--enable-sigchild'
Server API  Apache 2.0 Handler

Can't call an Oracle procedure returning collections with Oracle10g OCI8
lib.
A simple call to TEST_VARCHAR works (the result is outvarchar = 'VARCHAR
VALUE'), and the entire code works when using Oracle9i OCI8 lib.

With Oracle10g, the result is a hang of the httpd process at ociexecute(
$stmt ).

Oracle code :
-
CREATE OR REPLACE TYPE "COLLECTION_TYPE" AS TABLE OF VARCHAR2(255);
/

CREATE OR REPLACE PACKAGE TEST AS
PROCEDURE TEST_COLLECTION( OUTPARAM OUT COLLECTION_TYPE );
PROCEDURE TEST_VARCHAR( OUTPARAM OUT VARCHAR2 );
END;
/

CREATE OR REPLACE PACKAGE BODY TEST AS
PROCEDURE TEST_COLLECTION( OUTPARAM OUT COLLECTION_TYPE ) IS
BEGIN
OUTPARAM := COLLECTION_TYPE( 'FIRST VALUE', 'SECOND VALUE', 
'THIRD
VALUE' );
END;
PROCEDURE TEST_VARCHAR( OUTPARAM OUT VARCHAR2 ) IS
BEGIN
OUTPARAM := 'VARCHAR VALUE';
END;
END;
/

Reproduce code:
---
size(); $i++ )
{
echo( "outparam[$i] = '" . $outparam->getelem( $i ) . "'\n" );
}
$sql = "BEGIN\nTEST.TEST_VARCHAR( :outvarchar );\nEND;";
$stmt = ociparse( $cnx, $sql );
$outvarchar = '';
ocibindbyname( $stmt, ":outvarchar", &$outvarchar, 300 );
ociexecute( $stmt );
echo( "outvarchar = '" . $outvarchar . "'\n" );
?>

Expected result:

outparam[0] = 'FIRST VALUE'
outparam[1] = 'SECOND VALUE'
outparam[2] = 'THIRD VALUE'
outvarchar = 'VARCHAR VALUE'

Actual result:
--
no result !

-- 
Edit bug report at http://bugs.php.net/?id=32741&edit=1
-- 
Try a CVS snapshot (php4):   http://bugs.php.net/fix.php?id=32741&r=trysnapshot4
Try a CVS snapshot (php5.0): 
http://bugs.php.net/fix.php?id=32741&r=trysnapshot50
Try a CVS snapshot (php5.1): 
http://bugs.php.net/fix.php?id=32741&r=trysnapshot51
Fixed in CVS:http://bugs.php.net/fix.php?id=32741&r=fixedcvs
Fixed in release:http://bugs.php.net/fix.php?id=32741&r=alreadyfixed
Need backtrace:  http://bugs.php.net/fix.php?id=32741&r=needtrace
Need Reproduce Script:   http://bugs.php.net/fix.php?id=32741&r=needscript
Try newer version:   http://bugs.php.net/fix.php?id=32741&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=32741&r=support
Expected behavior:   http://bugs.php.net/fix.php?id=32741&r=notwrong
Not enough info: 
http://bugs.php.net/fix.php?id=32741&r=notenoughinfo
Submitted twice: 
http://bugs.php.net/fix.php?id=32741&r=submittedtwice
register_globals:http://bugs.php.net/fix.php?id=32741&r=globals
PHP 3 support discontinued:  http://bugs.php.net/fix.php?id=32741&r=php3
Daylight Savings:http://bugs.php.net/fix.php?id=32741&r=dst
IIS Stability:   http://bugs.php.net/fix.php?id=32741&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=32741&r=gnused
Floating point limitations:  http://bugs.php.net/fix.php?id=32741&r=float
No Zend Extensions:  http://bugs.php.net/fix.php?id=32741&r=nozend
MySQL Configuration Error:   http://bugs.php.net/fix.php?id=32741&r=mysqlcfg


#32741 [Opn->Fbk]: PHP hang on ociexecute with collections

2005-04-18 Thread sniper
 ID:   32741
 Updated by:   [EMAIL PROTECTED]
 Reported By:  fsurleau at skyservices dot net
-Status:   Open
+Status:   Feedback
 Bug Type: OCI8 related
 Operating System: linux
 PHP Version:  4.3.11
 New Comment:

Please try using this CVS snapshot:

  http://snaps.php.net/php5-latest.tar.gz
 
For Windows:
 
  http://snaps.php.net/win32/php5-win32-latest.zip




Previous Comments:


[2005-04-18 13:13:49] fsurleau at skyservices dot net

Reproduce Code is :

$cnx = ociplogon( USER_INTER, PASS_INTER, BD_INTER );
$sql = "BEGIN\nTEST.TEST_COLLECTION( :outparam );\nEND;";
$stmt = ociparse( $cnx, $sql );
$outparam = ocinewcollection( $cnx, "COLLECTION_TYPE" );
ocibindbyname( $stmt, ":outparam", &$outparam, -1, OCI_B_SQLT_NTY );
ociexecute( $stmt );
for( $i = 0; $i < $outparam->size(); $i++ )
{
echo( "outparam[$i] = '" . $outparam->getelem( $i ) . "'\n" );
}
$sql = "BEGIN\nTEST.TEST_VARCHAR( :outvarchar );\nEND;";
$stmt = ociparse( $cnx, $sql );
$outvarchar = '';
ocibindbyname( $stmt, ":outvarchar", &$outvarchar, 300 );
ociexecute( $stmt );
echo( "outvarchar = '" . $outvarchar . "'\n" );


It was cut at first post...



[2005-04-18 13:10:24] fsurleau at skyservices dot net

Description:

PHP Version 4.3.11

System  Linux dev1 2.4.9-e.48smp #1 SMP Fri Jul 30 18:52:05 EDT 2004
i686
Build Date  Apr 17 2005 16:44:16
Configure Command   './configure'
'--with-apxs2=/usr/local/apache2/bin/apxs' '--with-zlib-dir=/usr/local'
'--without-mysql' '--with-dom=/usr/local' '--with-dom-xslt'
'--with-dom-exslt' '--with-expat-dir=/usr/local' '--enable-xslt'
'--with-xslt-sablot' '--with-iconv-dir' '--with-zlib=/usr/local'
'--with-oci8=/usr/local/oracle10g' '--disable-rpath' '--with-iconv'
'--with-gd' '--enable-sigchild'
Server API  Apache 2.0 Handler

Can't call an Oracle procedure returning collections with Oracle10g
OCI8 lib.
A simple call to TEST_VARCHAR works (the result is outvarchar =
'VARCHAR VALUE'), and the entire code works when using Oracle9i OCI8
lib.

With Oracle10g, the result is a hang of the httpd process at
ociexecute( $stmt ).

Oracle code :
-
CREATE OR REPLACE TYPE "COLLECTION_TYPE" AS TABLE OF VARCHAR2(255);
/

CREATE OR REPLACE PACKAGE TEST AS
PROCEDURE TEST_COLLECTION( OUTPARAM OUT COLLECTION_TYPE );
PROCEDURE TEST_VARCHAR( OUTPARAM OUT VARCHAR2 );
END;
/

CREATE OR REPLACE PACKAGE BODY TEST AS
PROCEDURE TEST_COLLECTION( OUTPARAM OUT COLLECTION_TYPE ) IS
BEGIN
OUTPARAM := COLLECTION_TYPE( 'FIRST VALUE', 'SECOND VALUE', 
'THIRD
VALUE' );
END;
PROCEDURE TEST_VARCHAR( OUTPARAM OUT VARCHAR2 ) IS
BEGIN
OUTPARAM := 'VARCHAR VALUE';
END;
END;
/

Reproduce code:
---
size(); $i++ )
{
echo( "outparam[$i] = '" . $outparam->getelem( $i ) . "'\n" );
}
$sql = "BEGIN\nTEST.TEST_VARCHAR( :outvarchar );\nEND;";
$stmt = ociparse( $cnx, $sql );
$outvarchar = '';
ocibindbyname( $stmt, ":outvarchar", &$outvarchar, 300 );
ociexecute( $stmt );
echo( "outvarchar = '" . $outvarchar . "'\n" );
?>

Expected result:

outparam[0] = 'FIRST VALUE'
outparam[1] = 'SECOND VALUE'
outparam[2] = 'THIRD VALUE'
outvarchar = 'VARCHAR VALUE'

Actual result:
--
no result !





-- 
Edit this bug report at http://bugs.php.net/?id=32741&edit=1


#32722 [Opn->Fbk]: OCINewCollection hang after parse error.

2005-04-18 Thread sniper
 ID:   32722
 Updated by:   [EMAIL PROTECTED]
 Reported By:  fsurleau at skyservices dot net
-Status:   Open
+Status:   Feedback
 Bug Type: OCI8 related
 Operating System: linux
 PHP Version:  4.3.11
 New Comment:

Please try using this CVS snapshot:

  http://snaps.php.net/php5-latest.tar.gz
 
For Windows:
 
  http://snaps.php.net/win32/php5-win32-latest.zip

AFAIK, this might be fixed in PHP 5.1-dev..



Previous Comments:


[2005-04-15 18:20:53] fsurleau at skyservices dot net

Description:

Using OCI persistant connections, I found the folowing bug :

In case, there is a bug in one of my queries generating a parse error :
"ORA-01756: quoted string not properly terminated",
then, the next web request reusing the connection will have an
"OCI-21522: attempted to use an invalid connection in OCI (object mode
only)" error
at OCINewCollection call.

This bug occurs only if OCINewCollection was never used for the
persistant connection.

So a workaround is to call OCINewCollection, immediately after
OCIPLogon.

Of course the best is to only have correct SQL requests ;-)

Steps to reproduce the bug :

1- Stop and restart apache to kill all persistant connections.
2- Request for bad_query.php, and write down the PID.
3- Request for collection.php, and write down the PID.

If the PIDs are the same, collection.php will hang with OCI-21522
error.
If the PIDs are not the same, try again.

Now, try again, but run first collection.php :
1- Stop and restart apache to kill all persistant connections.
2- Request for collection.php, and write down the PID.
3- Request for bad_query.php, and write down the PID.

If the PID are the same, now each time you request collection.php, it
will not hang for the PID you wrote down.

Regards,
F.SURLEAU


Reproduce code:
---
// bad_query.php
";
}
echo "PID=" . getmypid();
?>

// collection.php
";
}
else
{
echo "OK for collection .";
}
echo "PID=" . getmypid();
?>


Expected result:

ORA-01756: quoted string not properly terminated

Actual result:
--
ORA-01756: quoted string not properly terminated
and
OCI-21522: attempted to use an invalid connection in OCI (object mode
only)
in some special cases.





-- 
Edit this bug report at http://bugs.php.net/?id=32722&edit=1


#32741 [Opn]: PHP hang on ociexecute with collections

2005-04-18 Thread fsurleau at skyservices dot net
 ID:   32741
 User updated by:  fsurleau at skyservices dot net
 Reported By:  fsurleau at skyservices dot net
 Status:   Open
 Bug Type: OCI8 related
 Operating System: linux
 PHP Version:  4.3.11
 New Comment:

Reproduce Code is :

$cnx = ociplogon( USER_INTER, PASS_INTER, BD_INTER );
$sql = "BEGIN\nTEST.TEST_COLLECTION( :outparam );\nEND;";
$stmt = ociparse( $cnx, $sql );
$outparam = ocinewcollection( $cnx, "COLLECTION_TYPE" );
ocibindbyname( $stmt, ":outparam", &$outparam, -1, OCI_B_SQLT_NTY );
ociexecute( $stmt );
for( $i = 0; $i < $outparam->size(); $i++ )
{
echo( "outparam[$i] = '" . $outparam->getelem( $i ) . "'\n" );
}
$sql = "BEGIN\nTEST.TEST_VARCHAR( :outvarchar );\nEND;";
$stmt = ociparse( $cnx, $sql );
$outvarchar = '';
ocibindbyname( $stmt, ":outvarchar", &$outvarchar, 300 );
ociexecute( $stmt );
echo( "outvarchar = '" . $outvarchar . "'\n" );


It was cut at first post...


Previous Comments:


[2005-04-18 13:10:24] fsurleau at skyservices dot net

Description:

PHP Version 4.3.11

System  Linux dev1 2.4.9-e.48smp #1 SMP Fri Jul 30 18:52:05 EDT 2004
i686
Build Date  Apr 17 2005 16:44:16
Configure Command   './configure'
'--with-apxs2=/usr/local/apache2/bin/apxs' '--with-zlib-dir=/usr/local'
'--without-mysql' '--with-dom=/usr/local' '--with-dom-xslt'
'--with-dom-exslt' '--with-expat-dir=/usr/local' '--enable-xslt'
'--with-xslt-sablot' '--with-iconv-dir' '--with-zlib=/usr/local'
'--with-oci8=/usr/local/oracle10g' '--disable-rpath' '--with-iconv'
'--with-gd' '--enable-sigchild'
Server API  Apache 2.0 Handler

Can't call an Oracle procedure returning collections with Oracle10g
OCI8 lib.
A simple call to TEST_VARCHAR works (the result is outvarchar =
'VARCHAR VALUE'), and the entire code works when using Oracle9i OCI8
lib.

With Oracle10g, the result is a hang of the httpd process at
ociexecute( $stmt ).

Oracle code :
-
CREATE OR REPLACE TYPE "COLLECTION_TYPE" AS TABLE OF VARCHAR2(255);
/

CREATE OR REPLACE PACKAGE TEST AS
PROCEDURE TEST_COLLECTION( OUTPARAM OUT COLLECTION_TYPE );
PROCEDURE TEST_VARCHAR( OUTPARAM OUT VARCHAR2 );
END;
/

CREATE OR REPLACE PACKAGE BODY TEST AS
PROCEDURE TEST_COLLECTION( OUTPARAM OUT COLLECTION_TYPE ) IS
BEGIN
OUTPARAM := COLLECTION_TYPE( 'FIRST VALUE', 'SECOND VALUE', 
'THIRD
VALUE' );
END;
PROCEDURE TEST_VARCHAR( OUTPARAM OUT VARCHAR2 ) IS
BEGIN
OUTPARAM := 'VARCHAR VALUE';
END;
END;
/

Reproduce code:
---
size(); $i++ )
{
echo( "outparam[$i] = '" . $outparam->getelem( $i ) . "'\n" );
}
$sql = "BEGIN\nTEST.TEST_VARCHAR( :outvarchar );\nEND;";
$stmt = ociparse( $cnx, $sql );
$outvarchar = '';
ocibindbyname( $stmt, ":outvarchar", &$outvarchar, 300 );
ociexecute( $stmt );
echo( "outvarchar = '" . $outvarchar . "'\n" );
?>

Expected result:

outparam[0] = 'FIRST VALUE'
outparam[1] = 'SECOND VALUE'
outparam[2] = 'THIRD VALUE'
outvarchar = 'VARCHAR VALUE'

Actual result:
--
no result !





-- 
Edit this bug report at http://bugs.php.net/?id=32741&edit=1


#28605 [Asn]: bug21523.phpt test never end

2005-04-18 Thread tbp at poly dot polytechnique dot fr
 ID:   28605
 User updated by:  tbp at poly dot polytechnique dot fr
 Reported By:  tbp at poly dot polytechnique dot fr
 Status:   Assigned
 Bug Type: Math related
 Operating System: Compaq Tru64 UNIX v5.1
 PHP Version:  4CVS-2005-03-21
 Assigned To:  helly
 New Comment:

You are right "-mieee" gcc option, fix this test problem:

[EMAIL PROTECTED]:/Admin/SRC/Apache/php4-STABLE-200504061830]# sapi/cli/php
ext/standard/tests/math/bug21523.phpt
--TEST--
Bug #21523 number_format tries to allocate negative amount of memory
--FILE--
string(2775)
"-2,000.0!
0!
0!
0"
OK--EXPECT--
string(2775)
"-2,000.0!
000

#32717 [Opn]: fgetcsv() against double quote

2005-04-18 Thread volf44 at yandex dot ru
 ID:   32717
 User updated by:  volf44 at yandex dot ru
 Reported By:  volf44 at yandex dot ru
 Status:   Open
 Bug Type: Filesystem function related
 Operating System: Linux, Windows 2k
-PHP Version:  4.3.10, .11
+PHP Version:  4.3.11
 New Comment:

-


Previous Comments:


[2005-04-18 12:58:04] volf44 at yandex dot ru

Oops, sorry. It seems I horried up to say "bogus".
Bug still exists in 4.3.11.



[2005-04-15 14:33:52] volf44 at yandex dot ru

Yes, bogus. In 4.3.11 function works as expected.



[2005-04-15 14:01:05] [EMAIL PROTECTED]

Thank you for taking the time to report a problem with PHP.
Unfortunately you are not using a current version of PHP -- 
the problem might already be fixed. Please download a new
PHP version from http://www.php.net/downloads.php

If you are able to reproduce the bug with one of the latest
versions of PHP, please change the PHP version on this bug report
to the version you tested and change the status back to "Open".
Again, thank you for your continued support of PHP.





[2005-04-15 13:56:55] volf44 at yandex dot ru

Description:

fgetcsv() incorrect handles single double quote
in first position of the last record field.

Reproduce code:
---
file test.csv:
one|record with bad double quote|"4
two|record with good "|4
[EOF]

$fd = fopen( 'test.csv', 'rb' );
while( $rec = fgetcsv( $fd, 20480, '|' )){
var_dump( $rec );
}


Expected result:

array(3) {
  [0]=>
  string(3) "one"
  [1]=>
  string(28) "record with bad double quote"
  [2]=>
  string(1) ""4"
}
array(3) {
  [0]=>
  string(3) "two"
  [1]=>
  string(18) "record with good ""
  [2]=>
  string(1) "4"
}

Actual result:
--
array(4) {
  [0]=>
  string(3) "one"
  [1]=>
  string(28) "record with bad double quote"
  [2]=>
  string(24) "4
two|record with good "
  [3]=>
  string(1) "4"
}





-- 
Edit this bug report at http://bugs.php.net/?id=32717&edit=1


#32717 [Bgs->Opn]: fgetcsv() against double quote

2005-04-18 Thread volf44 at yandex dot ru
 ID:   32717
 User updated by:  volf44 at yandex dot ru
 Reported By:  volf44 at yandex dot ru
-Status:   Bogus
+Status:   Open
 Bug Type: Filesystem function related
 Operating System: Linux, Windows 2k
-PHP Version:  4.3.10
+PHP Version:  4.3.10, .11
 New Comment:

Oops, sorry. It seems I horried up to say "bogus".
Bug still exists in 4.3.11.


Previous Comments:


[2005-04-15 14:33:52] volf44 at yandex dot ru

Yes, bogus. In 4.3.11 function works as expected.



[2005-04-15 14:01:05] [EMAIL PROTECTED]

Thank you for taking the time to report a problem with PHP.
Unfortunately you are not using a current version of PHP -- 
the problem might already be fixed. Please download a new
PHP version from http://www.php.net/downloads.php

If you are able to reproduce the bug with one of the latest
versions of PHP, please change the PHP version on this bug report
to the version you tested and change the status back to "Open".
Again, thank you for your continued support of PHP.





[2005-04-15 13:56:55] volf44 at yandex dot ru

Description:

fgetcsv() incorrect handles single double quote
in first position of the last record field.

Reproduce code:
---
file test.csv:
one|record with bad double quote|"4
two|record with good "|4
[EOF]

$fd = fopen( 'test.csv', 'rb' );
while( $rec = fgetcsv( $fd, 20480, '|' )){
var_dump( $rec );
}


Expected result:

array(3) {
  [0]=>
  string(3) "one"
  [1]=>
  string(28) "record with bad double quote"
  [2]=>
  string(1) ""4"
}
array(3) {
  [0]=>
  string(3) "two"
  [1]=>
  string(18) "record with good ""
  [2]=>
  string(1) "4"
}

Actual result:
--
array(4) {
  [0]=>
  string(3) "one"
  [1]=>
  string(28) "record with bad double quote"
  [2]=>
  string(24) "4
two|record with good "
  [3]=>
  string(1) "4"
}





-- 
Edit this bug report at http://bugs.php.net/?id=32717&edit=1


#32736 [Asn->WFx]: Select table.field returns wrong result index

2005-04-18 Thread wez
 ID:   32736
 Updated by:   [EMAIL PROTECTED]
 Reported By:  bart at mediawave dot nl
-Status:   Assigned
+Status:   Wont fix
 Bug Type: Feature/Change Request
 Operating System: WinXP
 PHP Version:  5.0.4
 Assigned To:  wez
 New Comment:

We leave sqlite in its default state for this kind of thing.
If you want to change the behaviour, you may issue a PRAGMA
full_column_names query.

http://sqlite.org/pragma.html




Previous Comments:


[2005-04-18 08:41:01] [EMAIL PROTECTED]

It can be, but don't count on it being changed... assigned to the
maintainer.



[2005-04-17 22:57:02] bart at mediawave dot nl

Can this be changed to a feature / change request? 

I've been looking around on the web. As far as I can see there are no
other SQL system that give results in such a way. This just makes it
unnecessarily difficult to write database independent code.

The only advantage I can think of for such a result is when tables that
have identical fieldnames need to be joined. But SQL (and SQLite)
already has aliases to solve that.

Maybe there should be a new SQLite result type constant for this?



[2005-04-17 12:27:51] [EMAIL PROTECTED]

Thank you for taking the time to write to us, but this is not
a bug. Please double-check the documentation available at
http://www.php.net/manual/ and the instructions on how to report
a bug at http://bugs.php.net/how-to-report.php

Sorry, but this is how SQLite works.



[2005-04-17 12:23:04] bart at mediawave dot nl

Description:

With the SQLite functions:

The problem occurs when selecting fields in a tablename.fieldname
manner. Example:

SELECT test.myfield, test.otherfield FROM test

The result array will have ['tablename.fieldname'] as index. This
should be just ['fieldname'] as index.

Reproduce code:
---


Expected result:

Array
(
[myfield] => value1
[otherfield] => value1
)
Array
(
[myfield] => value2
[otherfield] => value2
)

Actual result:
--
Array
(
[test.myfield] => value1
[test.otherfield] => value1
)
Array
(
[test.myfield] => value2
[test.otherfield] => value2
)





-- 
Edit this bug report at http://bugs.php.net/?id=32736&edit=1


#32742 [NEW]: segmentation fault when the stream with a wrapper is not closed (Linux RH only)

2005-04-18 Thread public at grik dot net
From: public at grik dot net
Operating system: Linux (RH7,RH9,Gentoo)
PHP version:  5.0.4
PHP Bug Type: Reproducible crash
Bug description:  segmentation fault when the stream with a wrapper is not 
closed (Linux RH only)

Description:

There is a problem with stream_wrapper_register() that appears on Linux
and not on the FreeBSD.
I open a stream with the registered wrapper and assing a handler to the
resource variable.
If a variable stays alive when the execution of the script reaches the
end, PHP gives the segmentation fault.
Attempt to close the resource from an object destructor does not help.

Platforms tested: 5 servers with Red Hat 7, 9 and gentoo 5.03 (kernels
2.4, 2.6, 2.6 hardened), PHP 5.03, 5.04, 4.3.7

In FreeBSD 5.3 there is no problem executing the script.

Reproduce code:
---
 

Expected result:

time with microseconds

Actual result:
--
When run from the command line - time with microseconds and words
"Segmentation fault",
when called from browser - no output.

-- 
Edit bug report at http://bugs.php.net/?id=32742&edit=1
-- 
Try a CVS snapshot (php4):   http://bugs.php.net/fix.php?id=32742&r=trysnapshot4
Try a CVS snapshot (php5.0): 
http://bugs.php.net/fix.php?id=32742&r=trysnapshot50
Try a CVS snapshot (php5.1): 
http://bugs.php.net/fix.php?id=32742&r=trysnapshot51
Fixed in CVS:http://bugs.php.net/fix.php?id=32742&r=fixedcvs
Fixed in release:http://bugs.php.net/fix.php?id=32742&r=alreadyfixed
Need backtrace:  http://bugs.php.net/fix.php?id=32742&r=needtrace
Need Reproduce Script:   http://bugs.php.net/fix.php?id=32742&r=needscript
Try newer version:   http://bugs.php.net/fix.php?id=32742&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=32742&r=support
Expected behavior:   http://bugs.php.net/fix.php?id=32742&r=notwrong
Not enough info: 
http://bugs.php.net/fix.php?id=32742&r=notenoughinfo
Submitted twice: 
http://bugs.php.net/fix.php?id=32742&r=submittedtwice
register_globals:http://bugs.php.net/fix.php?id=32742&r=globals
PHP 3 support discontinued:  http://bugs.php.net/fix.php?id=32742&r=php3
Daylight Savings:http://bugs.php.net/fix.php?id=32742&r=dst
IIS Stability:   http://bugs.php.net/fix.php?id=32742&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=32742&r=gnused
Floating point limitations:  http://bugs.php.net/fix.php?id=32742&r=float
No Zend Extensions:  http://bugs.php.net/fix.php?id=32742&r=nozend
MySQL Configuration Error:   http://bugs.php.net/fix.php?id=32742&r=mysqlcfg


#32742 [Opn]: segmentation fault when the stream with a wrapper is not closed (Linux RH only)

2005-04-18 Thread public at grik dot net
 ID:   32742
 User updated by:  public at grik dot net
 Reported By:  public at grik dot net
 Status:   Open
 Bug Type: Reproducible crash
 Operating System: Linux (RH7,RH9,Gentoo)
 PHP Version:  5.0.4
 New Comment:

The "reproduce code" disappeared (it was in the form, I checked). Here
it is:

class Wrapper{
function stream_open($path, $path, $options, &$opened_path){return
true;}
}

stream_wrapper_register("wr", 'Wrapper')
or die("Failed to register protocol");

$fp = fopen ('wr://example', 'w');

//fclose ($fp);
echo microtime();


Previous Comments:


[2005-04-18 14:44:29] public at grik dot net

Description:

There is a problem with stream_wrapper_register() that appears on Linux
and not on the FreeBSD.
I open a stream with the registered wrapper and assing a handler to the
resource variable.
If a variable stays alive when the execution of the script reaches the
end, PHP gives the segmentation fault.
Attempt to close the resource from an object destructor does not help.

Platforms tested: 5 servers with Red Hat 7, 9 and gentoo 5.03 (kernels
2.4, 2.6, 2.6 hardened), PHP 5.03, 5.04, 4.3.7

In FreeBSD 5.3 there is no problem executing the script.

Reproduce code:
---
 

Expected result:

time with microseconds

Actual result:
--
When run from the command line - time with microseconds and words
"Segmentation fault",
when called from browser - no output.





-- 
Edit this bug report at http://bugs.php.net/?id=32742&edit=1


#31990 [Opn->Bgs]: dblib.c:303: buffer_add_row: Assertion `row_size <= buf->element_size' failed

2005-04-18 Thread sniper
 ID:   31990
 Updated by:   [EMAIL PROTECTED]
 Reported By:  tim at datad dot com
-Status:   Open
+Status:   Bogus
 Bug Type: Sybase (dblib) related
 Operating System: SuSE 9.2 Pro 2.6.8-24.11-default
 PHP Version:  4CVS, 5CVS (2005-02-16)
 New Comment:

Eh..how do you expect it to work if you uninstall it??
It's a freetds bug anyway -> bogus.



Previous Comments:


[2005-02-16 22:36:18] tim at datad dot com

I believe this is a FreeTDS problem. 

I uninstalled FreeTDS, but now I can no longer connect at all.

Instead I get:

PHP Warning:  sybase_select_db(): Sybase:  A link to the server could
not be established in /srv/www/sybasedba/sybasedba.run_sp.php on line
17
PHP Warning:  sybase_query(): 0 is not a Sybase link index in
/srv/www/sybasedba/sybasedba.run_sp.php on line 21
PHP Warning:  sybase_num_fields(): 0 is not a Sybase result index in
/srv/www/sybasedba/sybasedba.run_sp.php on line 23
PHP Warning:  sybase_num_rows(): 0 is not a Sybase result index in
/srv/www/sybasedba/sybasedba.run_sp.php on line 24
PHP Warning:  sybase_fetch_row(): 0 is not a Sybase result index in
/srv/www/sybasedba/sybasedba.run_sp.php on line 29
PHP Warning:  sybase_close(): 0 is not a Sybase link index in
/srv/www/sybasedba/sybasedba.run_sp.php on line 62



What do I do to connect PHP to Sybase if I do not use FreeTDS?



[2005-02-16 05:16:00] tim at datad dot com

OK, so...

I downloaded and installed the latest PHP ( 4.3.11-dev ) and it still
exhibits the same behavior.

php: dblib.c:303: buffer_add_row: Assertion `row_size <=
buf->element_size' failed.
Aborted


Incidentally, you cannot configure 
--with-sybase
--with-sybase-ct

it has to be one or the other.  When I configured --with-ct I got
segfaults, and nothing worked at all.  I could not connect or anything
with either through a browser or php-cli.

I used --with-sybase-ct=/opt/sybase/OCS-12_5


So I've configured for --with-sybase=/opt/sybase and now what worked
before is working and it is producing the same error as before when I
try to use a stored procedure.

My latest configure:

./configure \
--enable-shared \
--with-apache2=../httpd-2.0.53 \
--with-module=so \
--with-apxs2=/usr/local/apache2/bin/apxs \
--with-mysql \
--with-gnu-ld \
--with-zlib \
--with-sybase=/opt/sybase \
--with-unixODBC \
--with-dbase \
--with-openssl \
--with-gd \
--with-ttf \
--with-curl \
--with-mcrypt



[2005-02-16 03:18:29] [EMAIL PROTECTED]

Please try using this CVS snapshot:

  http://snaps.php.net/php4-STABLE-latest.tar.gz
 
For Windows:
 
  http://snaps.php.net/win32/php4-win32-STABLE-latest.zip

And why don't you use --with-sybase-ct ?? AFAIK, it's better supported
than the old sybase-db..




[2005-02-16 02:25:34] tim at datad dot com

Description:

I get the following error when I run any stored procedure.  The script
works fine if you use SQL statements, but sp's die.



php: dblib.c:303: buffer_add_row: Assertion `row_size <=
buf->element_size' failed.
Aborted

My PHP Configuration:

./configure \
--with-apache2=../httpd-2.0.53 \
--enable-track-vars \
--enable-magic-quotes \
--enable-discard-path \
--enable-force-cgi-redirect \
--enable-shared \
--enable-sigchild \
--enable-sockets=shared \
--enable-mailparse \
--with-module=so \
--with-apxs2=/usr/local/apache2/bin/apxs \
--with-mysql \
--with-gnu-ld \
--with-zlib \
--with-sybase \
--with-tdsver=7.0 \
--with-unixODBC \
--with-dbase \
--with-openssl \
--with-gd \
--with-ttf \
--with-curl \
--with-mcrypt


Reproduce code:
---
name]";
if ( $field_cnt == $syb_num_fields )
{
print "\n" ;
$field_cnt = 0 ;
}
}
print "\n" ;
}

++$row_cnt ;
$field_cnt = 0 ;
while(list($k, $v) = each($row))
{
++$field_cnt;
$datum = NULL ;
$datum = rtrim ( $v ) ;
print "[$datum]" ;
if ( $field_cnt == $syb_num_fields )
{
print "\n" ;
$field_cnt = 0 ;
}
}
}
sybase_close ( $db ) ;

?>

Expected result:

I expect it to work!

I should see the output of the stored procedure or at least some kind
of explanation as to why it's failing.

Actual result:
--

#28006 [Opn->Csd]: referencing an unset global produces a segfault

2005-04-18 Thread sniper
 ID:   28006
 Updated by:   [EMAIL PROTECTED]
 Reported By:  per at computer dot org
-Status:   Open
+Status:   Closed
 Bug Type: Reproducible crash
 Operating System: linux, kernel 2.4.26
 PHP Version:  4CVS-2005-01-10
 New Comment:

So do we, so do we..:) As long as it works -> closed.



Previous Comments:


[2005-04-16 08:30:34] per at computer dot org

I've tested this again with 4.3.11 and it appears to have been fixed. 
I'd be interested to know what really happened.



[2005-02-17 13:32:10] per at computer dot org

Um, well ... :-)
It was php4-STABLE-200502110930, and I've just now tried
php4-STABLE-200502170730 - also works fine.  If need be, I can try out
5.1-dev too.



[2005-02-17 06:31:54] [EMAIL PROTECTED]

Are you sure it was PHP 4 ? :)
I asked you to try the latest HEAD (PHP 5.1-dev)..
If it really was the PHP 4 snapshot, I must ask you to try again the
current one: 
 
  http://snaps.php.net/php4-STABLE-latest.tar.gz

If the bug appears again with this snapshot, I'll have pretty good idea
what fixes it.





[2005-02-11 11:51:31] per at computer dot org

OK, I tried php4-STABLE-200502110930.tar.gz, and it appears to have
been fixed.  I'd be interested to know what really caused it?  Thanks.



[2005-02-11 06:19:38] [EMAIL PROTECTED]

Please try using this CVS snapshot:

  http://snaps.php.net/php5-latest.tar.gz
 
For Windows:
 
  http://snaps.php.net/win32/php5-win32-latest.zip





The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/28006

-- 
Edit this bug report at http://bugs.php.net/?id=28006&edit=1


#32717 [Opn->Bgs]: fgetcsv() against double quote

2005-04-18 Thread iliaa
 ID:   32717
 Updated by:   [EMAIL PROTECTED]
 Reported By:  volf44 at yandex dot ru
-Status:   Open
+Status:   Bogus
 Bug Type: Filesystem function related
 Operating System: Linux, Windows 2k
 PHP Version:  4.3.11
 New Comment:

Thank you for taking the time to write to us, but this is not
a bug. Please double-check the documentation available at
http://www.php.net/manual/ and the instructions on how to report
a bug at http://bugs.php.net/how-to-report.php

This is to be expected, quoted text can contain new lines, so "4 will
continue until the closing quote is found. 


Previous Comments:


[2005-04-15 13:56:55] volf44 at yandex dot ru

Description:

fgetcsv() incorrect handles single double quote
in first position of the last record field.

Reproduce code:
---
file test.csv:
one|record with bad double quote|"4
two|record with good "|4
[EOF]

$fd = fopen( 'test.csv', 'rb' );
while( $rec = fgetcsv( $fd, 20480, '|' )){
var_dump( $rec );
}


Expected result:

array(3) {
  [0]=>
  string(3) "one"
  [1]=>
  string(28) "record with bad double quote"
  [2]=>
  string(1) ""4"
}
array(3) {
  [0]=>
  string(3) "two"
  [1]=>
  string(18) "record with good ""
  [2]=>
  string(1) "4"
}

Actual result:
--
array(4) {
  [0]=>
  string(3) "one"
  [1]=>
  string(28) "record with bad double quote"
  [2]=>
  string(24) "4
two|record with good "
  [3]=>
  string(1) "4"
}





-- 
Edit this bug report at http://bugs.php.net/?id=32717&edit=1


#31990 [Bgs->Csd]: dblib.c:303: buffer_add_row: Assertion `row_size <= buf->element_size' failed

2005-04-18 Thread tim at datad dot com
 ID:   31990
 User updated by:  tim at datad dot com
 Reported By:  tim at datad dot com
-Status:   Bogus
+Status:   Closed
 Bug Type: Sybase (dblib) related
 Operating System: SuSE 9.2 Pro 2.6.8-24.11-default
 PHP Version:  4CVS, 5CVS (2005-02-16)
 New Comment:

Thanks dude.  I figured this out what TWO MONTHS AGO.

:-)

What I was trying to figure out is if I can live without FreeTDS and
simply use Sybases' connection library.  It's too confusing which or
what to use, so I went back to FreeTDS for what I **can** do, and wrote
a shell wrapper for stored procs that return more than one result
set--which is quite a few standard "supplied" stored procs that come
with Sybase, like sp_help, etc.


Thanks anyway!


Previous Comments:


[2005-04-18 15:17:05] [EMAIL PROTECTED]

Eh..how do you expect it to work if you uninstall it??
It's a freetds bug anyway -> bogus.




[2005-02-16 22:36:18] tim at datad dot com

I believe this is a FreeTDS problem. 

I uninstalled FreeTDS, but now I can no longer connect at all.

Instead I get:

PHP Warning:  sybase_select_db(): Sybase:  A link to the server could
not be established in /srv/www/sybasedba/sybasedba.run_sp.php on line
17
PHP Warning:  sybase_query(): 0 is not a Sybase link index in
/srv/www/sybasedba/sybasedba.run_sp.php on line 21
PHP Warning:  sybase_num_fields(): 0 is not a Sybase result index in
/srv/www/sybasedba/sybasedba.run_sp.php on line 23
PHP Warning:  sybase_num_rows(): 0 is not a Sybase result index in
/srv/www/sybasedba/sybasedba.run_sp.php on line 24
PHP Warning:  sybase_fetch_row(): 0 is not a Sybase result index in
/srv/www/sybasedba/sybasedba.run_sp.php on line 29
PHP Warning:  sybase_close(): 0 is not a Sybase link index in
/srv/www/sybasedba/sybasedba.run_sp.php on line 62



What do I do to connect PHP to Sybase if I do not use FreeTDS?



[2005-02-16 05:16:00] tim at datad dot com

OK, so...

I downloaded and installed the latest PHP ( 4.3.11-dev ) and it still
exhibits the same behavior.

php: dblib.c:303: buffer_add_row: Assertion `row_size <=
buf->element_size' failed.
Aborted


Incidentally, you cannot configure 
--with-sybase
--with-sybase-ct

it has to be one or the other.  When I configured --with-ct I got
segfaults, and nothing worked at all.  I could not connect or anything
with either through a browser or php-cli.

I used --with-sybase-ct=/opt/sybase/OCS-12_5


So I've configured for --with-sybase=/opt/sybase and now what worked
before is working and it is producing the same error as before when I
try to use a stored procedure.

My latest configure:

./configure \
--enable-shared \
--with-apache2=../httpd-2.0.53 \
--with-module=so \
--with-apxs2=/usr/local/apache2/bin/apxs \
--with-mysql \
--with-gnu-ld \
--with-zlib \
--with-sybase=/opt/sybase \
--with-unixODBC \
--with-dbase \
--with-openssl \
--with-gd \
--with-ttf \
--with-curl \
--with-mcrypt



[2005-02-16 03:18:29] [EMAIL PROTECTED]

Please try using this CVS snapshot:

  http://snaps.php.net/php4-STABLE-latest.tar.gz
 
For Windows:
 
  http://snaps.php.net/win32/php4-win32-STABLE-latest.zip

And why don't you use --with-sybase-ct ?? AFAIK, it's better supported
than the old sybase-db..




[2005-02-16 02:25:34] tim at datad dot com

Description:

I get the following error when I run any stored procedure.  The script
works fine if you use SQL statements, but sp's die.



php: dblib.c:303: buffer_add_row: Assertion `row_size <=
buf->element_size' failed.
Aborted

My PHP Configuration:

./configure \
--with-apache2=../httpd-2.0.53 \
--enable-track-vars \
--enable-magic-quotes \
--enable-discard-path \
--enable-force-cgi-redirect \
--enable-shared \
--enable-sigchild \
--enable-sockets=shared \
--enable-mailparse \
--with-module=so \
--with-apxs2=/usr/local/apache2/bin/apxs \
--with-mysql \
--with-gnu-ld \
--with-zlib \
--with-sybase \
--with-tdsver=7.0 \
--with-unixODBC \
--with-dbase \
--with-openssl \
--with-gd \
--with-ttf \
--with-curl \
--with-mcrypt


Reproduce code:
---
name]";
if ( $field_cnt == $syb_num_fields )
{
print "\n" ;
$field_cnt = 0 ;
}
}
print "\n" ;
}

++$row_cnt ;
$field_cnt = 0 ;
while(list($k, $v) = each($row))
{
++$field_cnt;
$datum = NULL ;
   

#32736 [WFx]: Select table.field returns wrong result index

2005-04-18 Thread bart at mediawave dot nl
 ID:   32736
 User updated by:  bart at mediawave dot nl
 Reported By:  bart at mediawave dot nl
 Status:   Wont fix
 Bug Type: Feature/Change Request
 Operating System: WinXP
 PHP Version:  5.0.4
 Assigned To:  wez
 New Comment:

WFM... 

sqlite_query($connectionId, 'PRAGMA short_column_names = 1');


Previous Comments:


[2005-04-18 14:02:51] [EMAIL PROTECTED]

We leave sqlite in its default state for this kind of thing.
If you want to change the behaviour, you may issue a PRAGMA
full_column_names query.

http://sqlite.org/pragma.html





[2005-04-18 08:41:01] [EMAIL PROTECTED]

It can be, but don't count on it being changed... assigned to the
maintainer.



[2005-04-17 22:57:02] bart at mediawave dot nl

Can this be changed to a feature / change request? 

I've been looking around on the web. As far as I can see there are no
other SQL system that give results in such a way. This just makes it
unnecessarily difficult to write database independent code.

The only advantage I can think of for such a result is when tables that
have identical fieldnames need to be joined. But SQL (and SQLite)
already has aliases to solve that.

Maybe there should be a new SQLite result type constant for this?



[2005-04-17 12:27:51] [EMAIL PROTECTED]

Thank you for taking the time to write to us, but this is not
a bug. Please double-check the documentation available at
http://www.php.net/manual/ and the instructions on how to report
a bug at http://bugs.php.net/how-to-report.php

Sorry, but this is how SQLite works.



[2005-04-17 12:23:04] bart at mediawave dot nl

Description:

With the SQLite functions:

The problem occurs when selecting fields in a tablename.fieldname
manner. Example:

SELECT test.myfield, test.otherfield FROM test

The result array will have ['tablename.fieldname'] as index. This
should be just ['fieldname'] as index.

Reproduce code:
---


Expected result:

Array
(
[myfield] => value1
[otherfield] => value1
)
Array
(
[myfield] => value2
[otherfield] => value2
)

Actual result:
--
Array
(
[test.myfield] => value1
[test.otherfield] => value1
)
Array
(
[test.myfield] => value2
[test.otherfield] => value2
)





-- 
Edit this bug report at http://bugs.php.net/?id=32736&edit=1


#32743 [NEW]: Error with type of 2nd parameter when creating DOMDocument()

2005-04-18 Thread jj at intelequest dot com
From: jj at intelequest dot com
Operating system: Windows XP
PHP version:  5.0.4
PHP Bug Type: DOM XML related
Bug description:  Error with type of 2nd parameter when creating DOMDocument()

Description:

When executing the demo code found at
http://www.php.net/manual/en/function.dom-domdocument-construct.php I
obtain the error message.

"Warning: domdocument() expects parameter 2 to be long"

My understanding (from the online docs) is that the 2nd parameter is to be
of type string.

Also, according to the documentation, this is the php 5 replacment to
DOM_XML i.e. this is DOM XML. Note that there is no sub-category for just
DOM so the next logical place to put errors such as these would be either
DOM XML or Documentation bug.



Reproduce code:
---
saveXML();
?>



Expected result:



Actual result:
--
Warning: domdocument() expects parameter 2 to be long, string given in
C:\temp\test_xml.php on line 2

Fatal error: Call to undefined method domdocument::saveXML() in
C:\temp\test_xml.php on line 3

-- 
Edit bug report at http://bugs.php.net/?id=32743&edit=1
-- 
Try a CVS snapshot (php4):   http://bugs.php.net/fix.php?id=32743&r=trysnapshot4
Try a CVS snapshot (php5.0): 
http://bugs.php.net/fix.php?id=32743&r=trysnapshot50
Try a CVS snapshot (php5.1): 
http://bugs.php.net/fix.php?id=32743&r=trysnapshot51
Fixed in CVS:http://bugs.php.net/fix.php?id=32743&r=fixedcvs
Fixed in release:http://bugs.php.net/fix.php?id=32743&r=alreadyfixed
Need backtrace:  http://bugs.php.net/fix.php?id=32743&r=needtrace
Need Reproduce Script:   http://bugs.php.net/fix.php?id=32743&r=needscript
Try newer version:   http://bugs.php.net/fix.php?id=32743&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=32743&r=support
Expected behavior:   http://bugs.php.net/fix.php?id=32743&r=notwrong
Not enough info: 
http://bugs.php.net/fix.php?id=32743&r=notenoughinfo
Submitted twice: 
http://bugs.php.net/fix.php?id=32743&r=submittedtwice
register_globals:http://bugs.php.net/fix.php?id=32743&r=globals
PHP 3 support discontinued:  http://bugs.php.net/fix.php?id=32743&r=php3
Daylight Savings:http://bugs.php.net/fix.php?id=32743&r=dst
IIS Stability:   http://bugs.php.net/fix.php?id=32743&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=32743&r=gnused
Floating point limitations:  http://bugs.php.net/fix.php?id=32743&r=float
No Zend Extensions:  http://bugs.php.net/fix.php?id=32743&r=nozend
MySQL Configuration Error:   http://bugs.php.net/fix.php?id=32743&r=mysqlcfg


#32744 [NEW]: possible twice including by require_once() after chdir()

2005-04-18 Thread vovik at getart dot ru
From: vovik at getart dot ru
Operating system: Windows XP
PHP version:  4.3.11
PHP Bug Type: Filesystem function related
Bug description:  possible twice including by require_once() after chdir()

Description:

When script started and do require_once() by relative filename, this
function remembers lower case real path.
If script changes working dir via chdir() and directory name consist of
not lower-case letters, require_once() will include the file again.

Reproduce code:
---
";

require_once("./inc.php"); // single print line there

chdir("./..");
chdir("./TesT");

require_once("./inc.php");

var_dump(get_included_files());
?>

Expected result:

I expect to single include of inc.php.

Actual result:
--
Actually, got two :)

-- 
Edit bug report at http://bugs.php.net/?id=32744&edit=1
-- 
Try a CVS snapshot (php4):   http://bugs.php.net/fix.php?id=32744&r=trysnapshot4
Try a CVS snapshot (php5.0): 
http://bugs.php.net/fix.php?id=32744&r=trysnapshot50
Try a CVS snapshot (php5.1): 
http://bugs.php.net/fix.php?id=32744&r=trysnapshot51
Fixed in CVS:http://bugs.php.net/fix.php?id=32744&r=fixedcvs
Fixed in release:http://bugs.php.net/fix.php?id=32744&r=alreadyfixed
Need backtrace:  http://bugs.php.net/fix.php?id=32744&r=needtrace
Need Reproduce Script:   http://bugs.php.net/fix.php?id=32744&r=needscript
Try newer version:   http://bugs.php.net/fix.php?id=32744&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=32744&r=support
Expected behavior:   http://bugs.php.net/fix.php?id=32744&r=notwrong
Not enough info: 
http://bugs.php.net/fix.php?id=32744&r=notenoughinfo
Submitted twice: 
http://bugs.php.net/fix.php?id=32744&r=submittedtwice
register_globals:http://bugs.php.net/fix.php?id=32744&r=globals
PHP 3 support discontinued:  http://bugs.php.net/fix.php?id=32744&r=php3
Daylight Savings:http://bugs.php.net/fix.php?id=32744&r=dst
IIS Stability:   http://bugs.php.net/fix.php?id=32744&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=32744&r=gnused
Floating point limitations:  http://bugs.php.net/fix.php?id=32744&r=float
No Zend Extensions:  http://bugs.php.net/fix.php?id=32744&r=nozend
MySQL Configuration Error:   http://bugs.php.net/fix.php?id=32744&r=mysqlcfg


#32742 [Opn->Asn]: segmentation fault when the stream with a wrapper is not closed (Linux RH only)

2005-04-18 Thread tony2001
 ID:   32742
 Updated by:   [EMAIL PROTECTED]
 Reported By:  public at grik dot net
-Status:   Open
+Status:   Assigned
 Bug Type: Reproducible crash
 Operating System: Linux (RH7,RH9,Gentoo)
 PHP Version:  5.0.4
-Assigned To:  
+Assigned To:  pollita
 New Comment:

Sara, you seem to be patching streams hard these days, please take a
look at it.
Looks like there is some memory corruption (but valgrind complains only
about invalid reads and tells nothing about invalid writes). 


Previous Comments:


[2005-04-18 16:35:53] [EMAIL PROTECTED]

Here is the backtrace (pay attention to the last line):
(gdb) bt
#0  0x0018 in ?? ()
#1  0x0817f8a6 in _php_stream_free (stream=0x82b8cb4, close_options=11)
at /usr/src/dev/clean/php-src_5_0/main/streams/streams.c:351
#2  0x081814d8 in stream_resource_regular_dtor (rsrc=0x82b8d40) at
/usr/src/dev/clean/php-src_5_0/main/streams/streams.c:1361
#3  0x081b6e2f in list_entry_destructor (ptr=0x82b8d40) at
/usr/src/dev/clean/php-src_5_0/Zend/zend_list.c:178
#4  0x081b517a in zend_hash_del_key_or_index (ht=0x82372fc, arKey=0x0,
nKeyLength=0, h=6, flag=1) at
/usr/src/dev/clean/php-src_5_0/Zend/zend_hash.c:490
#5  0x081b6b8d in _zend_list_delete (id=6) at
/usr/src/dev/clean/php-src_5_0/Zend/zend_list.c:58
#6  0x081acff6 in _zval_dtor (zvalue=0x82b8998,
__zend_filename=0x8216844
"/usr/src/dev/clean/php-src_5_0/Zend/zend_execute_API.c",
__zend_lineno=392)
at /usr/src/dev/clean/php-src_5_0/Zend/zend_variables.c:69
#7  0x081a2d23 in _zval_ptr_dtor (zval_ptr=0x82b8bfc,
__zend_filename=0x8217570
"/usr/src/dev/clean/php-src_5_0/Zend/zend_variables.c",
__zend_lineno=193)
at /usr/src/dev/clean/php-src_5_0/Zend/zend_execute_API.c:392
#8  0x081ad275 in _zval_ptr_dtor_wrapper (zval_ptr=0x82b8bfc) at
/usr/src/dev/clean/php-src_5_0/Zend/zend_variables.c:193
#9  0x081b53b5 in zend_hash_apply_deleter (ht=0x82371d0, p=0x82b8bf0)
at /usr/src/dev/clean/php-src_5_0/Zend/zend_hash.c:574
#10 0x081b555f in zend_hash_graceful_reverse_destroy (ht=0x82371d0) at
/usr/src/dev/clean/php-src_5_0/Zend/zend_hash.c:640
#11 0x081a26ab in shutdown_executor () at
/usr/src/dev/clean/php-src_5_0/Zend/zend_execute_API.c:208
#12 0x081ae443 in zend_deactivate () at
/usr/src/dev/clean/php-src_5_0/Zend/zend.c:817
#13 0x081700a7 in php_request_shutdown (dummy=0x0) at
/usr/src/dev/clean/php-src_5_0/main/main.c:1214
#14 0x081dc2f6 in main (argc=2, argv=0xb154) at
/usr/src/dev/clean/php-src_5_0/sapi/cli/php_cli.c:1049
(gdb) f 1
#1  0x0817f8a6 in _php_stream_free (stream=0x82b8cb4, close_options=11)
at /usr/src/dev/clean/php-src_5_0/main/streams/streams.c:351
351
stream->wrapper->wops->stream_closer(stream->wrapper, stream
TSRMLS_CC);
(gdb) p *stream.wrapper.wops
$1 = {stream_opener = 0x4480, stream_closer = 0x18, stream_stat =
0x82a67b0, url_stat = 0, dir_opener = 0x1, label = 0x0, unlink = 0,
rename = 0x31,
  stream_mkdir = 0x82a67c8, stream_rmdir = 0x2}



[2005-04-18 14:47:05] public at grik dot net

The "reproduce code" disappeared (it was in the form, I checked). Here
it is:

class Wrapper{
function stream_open($path, $path, $options, &$opened_path){return
true;}
}

stream_wrapper_register("wr", 'Wrapper')
or die("Failed to register protocol");

$fp = fopen ('wr://example', 'w');

//fclose ($fp);
echo microtime();



[2005-04-18 14:44:29] public at grik dot net

Description:

There is a problem with stream_wrapper_register() that appears on Linux
and not on the FreeBSD.
I open a stream with the registered wrapper and assing a handler to the
resource variable.
If a variable stays alive when the execution of the script reaches the
end, PHP gives the segmentation fault.
Attempt to close the resource from an object destructor does not help.

Platforms tested: 5 servers with Red Hat 7, 9 and gentoo 5.03 (kernels
2.4, 2.6, 2.6 hardened), PHP 5.03, 5.04, 4.3.7

In FreeBSD 5.3 there is no problem executing the script.

Reproduce code:
---
 

Expected result:

time with microseconds

Actual result:
--
When run from the command line - time with microseconds and words
"Segmentation fault",
when called from browser - no output.





-- 
Edit this bug report at http://bugs.php.net/?id=32742&edit=1


#32744 [Opn->Bgs]: possible twice including by require_once() after chdir()

2005-04-18 Thread derick
 ID:   32744
 Updated by:   [EMAIL PROTECTED]
 Reported By:  vovik at getart dot ru
-Status:   Open
+Status:   Bogus
 Bug Type: Filesystem function related
 Operating System: Windows XP
 PHP Version:  4.3.11
 New Comment:

Please do not submit the same bug more than once. An existing
bug report already describes this very problem. Even if you feel
that your issue is somewhat different, the resolution is likely
to be the same. 

Thank you for your interest in PHP.

(And this is also expected)


Previous Comments:


[2005-04-18 16:31:58] vovik at getart dot ru

I've pasted the reproduce code with php tags and it was stripped. Here
is it:

// This file located under directory with non-lowercase name, i.e.
"TesT"
print "";

require_once("./inc.php"); // single print line there

chdir("./..");
chdir("./TesT");

require_once("./inc.php");

var_dump(get_included_files());



[2005-04-18 16:29:23] vovik at getart dot ru

Description:

When script started and do require_once() by relative filename, this
function remembers lower case real path.
If script changes working dir via chdir() and directory name consist of
not lower-case letters, require_once() will include the file again.

Reproduce code:
---
";

require_once("./inc.php"); // single print line there

chdir("./..");
chdir("./TesT");

require_once("./inc.php");

var_dump(get_included_files());
?>

Expected result:

I expect to single include of inc.php.

Actual result:
--
Actually, got two :)





-- 
Edit this bug report at http://bugs.php.net/?id=32744&edit=1


#32743 [Opn]: Error with type of 2nd parameter when creating DOMDocument()

2005-04-18 Thread jj at intelequest dot com
 ID:   32743
 User updated by:  jj at intelequest dot com
 Reported By:  jj at intelequest dot com
 Status:   Open
 Bug Type: DOM XML related
 Operating System: Windows XP
 PHP Version:  5.0.4
 New Comment:

The reproduce code is as follows:

$dom = new DOMDocument('1.0', 'iso-8859-1');
echo $dom->saveXML();


Previous Comments:


[2005-04-18 16:27:58] jj at intelequest dot com

Description:

When executing the demo code found at
http://www.php.net/manual/en/function.dom-domdocument-construct.php I
obtain the error message.

"Warning: domdocument() expects parameter 2 to be long"

My understanding (from the online docs) is that the 2nd parameter is to
be of type string.

Also, according to the documentation, this is the php 5 replacment to
DOM_XML i.e. this is DOM XML. Note that there is no sub-category for
just DOM so the next logical place to put errors such as these would be
either DOM XML or Documentation bug.



Reproduce code:
---
saveXML();
?>



Expected result:



Actual result:
--
Warning: domdocument() expects parameter 2 to be long, string given in
C:\temp\test_xml.php on line 2

Fatal error: Call to undefined method domdocument::saveXML() in
C:\temp\test_xml.php on line 3





-- 
Edit this bug report at http://bugs.php.net/?id=32743&edit=1


#32744 [Opn]: possible twice including by require_once() after chdir()

2005-04-18 Thread vovik at getart dot ru
 ID:   32744
 User updated by:  vovik at getart dot ru
 Reported By:  vovik at getart dot ru
 Status:   Open
 Bug Type: Filesystem function related
 Operating System: Windows XP
 PHP Version:  4.3.11
 New Comment:

I've pasted the reproduce code with php tags and it was stripped. Here
is it:

// This file located under directory with non-lowercase name, i.e.
"TesT"
print "";

require_once("./inc.php"); // single print line there

chdir("./..");
chdir("./TesT");

require_once("./inc.php");

var_dump(get_included_files());


Previous Comments:


[2005-04-18 16:29:23] vovik at getart dot ru

Description:

When script started and do require_once() by relative filename, this
function remembers lower case real path.
If script changes working dir via chdir() and directory name consist of
not lower-case letters, require_once() will include the file again.

Reproduce code:
---
";

require_once("./inc.php"); // single print line there

chdir("./..");
chdir("./TesT");

require_once("./inc.php");

var_dump(get_included_files());
?>

Expected result:

I expect to single include of inc.php.

Actual result:
--
Actually, got two :)





-- 
Edit this bug report at http://bugs.php.net/?id=32744&edit=1


#32742 [Opn]: segmentation fault when the stream with a wrapper is not closed (Linux RH only)

2005-04-18 Thread tony2001
 ID:   32742
 Updated by:   [EMAIL PROTECTED]
 Reported By:  public at grik dot net
 Status:   Open
 Bug Type: Reproducible crash
 Operating System: Linux (RH7,RH9,Gentoo)
 PHP Version:  5.0.4
 New Comment:

Here is the backtrace (pay attention to the last line):
(gdb) bt
#0  0x0018 in ?? ()
#1  0x0817f8a6 in _php_stream_free (stream=0x82b8cb4, close_options=11)
at /usr/src/dev/clean/php-src_5_0/main/streams/streams.c:351
#2  0x081814d8 in stream_resource_regular_dtor (rsrc=0x82b8d40) at
/usr/src/dev/clean/php-src_5_0/main/streams/streams.c:1361
#3  0x081b6e2f in list_entry_destructor (ptr=0x82b8d40) at
/usr/src/dev/clean/php-src_5_0/Zend/zend_list.c:178
#4  0x081b517a in zend_hash_del_key_or_index (ht=0x82372fc, arKey=0x0,
nKeyLength=0, h=6, flag=1) at
/usr/src/dev/clean/php-src_5_0/Zend/zend_hash.c:490
#5  0x081b6b8d in _zend_list_delete (id=6) at
/usr/src/dev/clean/php-src_5_0/Zend/zend_list.c:58
#6  0x081acff6 in _zval_dtor (zvalue=0x82b8998,
__zend_filename=0x8216844
"/usr/src/dev/clean/php-src_5_0/Zend/zend_execute_API.c",
__zend_lineno=392)
at /usr/src/dev/clean/php-src_5_0/Zend/zend_variables.c:69
#7  0x081a2d23 in _zval_ptr_dtor (zval_ptr=0x82b8bfc,
__zend_filename=0x8217570
"/usr/src/dev/clean/php-src_5_0/Zend/zend_variables.c",
__zend_lineno=193)
at /usr/src/dev/clean/php-src_5_0/Zend/zend_execute_API.c:392
#8  0x081ad275 in _zval_ptr_dtor_wrapper (zval_ptr=0x82b8bfc) at
/usr/src/dev/clean/php-src_5_0/Zend/zend_variables.c:193
#9  0x081b53b5 in zend_hash_apply_deleter (ht=0x82371d0, p=0x82b8bf0)
at /usr/src/dev/clean/php-src_5_0/Zend/zend_hash.c:574
#10 0x081b555f in zend_hash_graceful_reverse_destroy (ht=0x82371d0) at
/usr/src/dev/clean/php-src_5_0/Zend/zend_hash.c:640
#11 0x081a26ab in shutdown_executor () at
/usr/src/dev/clean/php-src_5_0/Zend/zend_execute_API.c:208
#12 0x081ae443 in zend_deactivate () at
/usr/src/dev/clean/php-src_5_0/Zend/zend.c:817
#13 0x081700a7 in php_request_shutdown (dummy=0x0) at
/usr/src/dev/clean/php-src_5_0/main/main.c:1214
#14 0x081dc2f6 in main (argc=2, argv=0xb154) at
/usr/src/dev/clean/php-src_5_0/sapi/cli/php_cli.c:1049
(gdb) f 1
#1  0x0817f8a6 in _php_stream_free (stream=0x82b8cb4, close_options=11)
at /usr/src/dev/clean/php-src_5_0/main/streams/streams.c:351
351
stream->wrapper->wops->stream_closer(stream->wrapper, stream
TSRMLS_CC);
(gdb) p *stream.wrapper.wops
$1 = {stream_opener = 0x4480, stream_closer = 0x18, stream_stat =
0x82a67b0, url_stat = 0, dir_opener = 0x1, label = 0x0, unlink = 0,
rename = 0x31,
  stream_mkdir = 0x82a67c8, stream_rmdir = 0x2}


Previous Comments:


[2005-04-18 14:47:05] public at grik dot net

The "reproduce code" disappeared (it was in the form, I checked). Here
it is:

class Wrapper{
function stream_open($path, $path, $options, &$opened_path){return
true;}
}

stream_wrapper_register("wr", 'Wrapper')
or die("Failed to register protocol");

$fp = fopen ('wr://example', 'w');

//fclose ($fp);
echo microtime();



[2005-04-18 14:44:29] public at grik dot net

Description:

There is a problem with stream_wrapper_register() that appears on Linux
and not on the FreeBSD.
I open a stream with the registered wrapper and assing a handler to the
resource variable.
If a variable stays alive when the execution of the script reaches the
end, PHP gives the segmentation fault.
Attempt to close the resource from an object destructor does not help.

Platforms tested: 5 servers with Red Hat 7, 9 and gentoo 5.03 (kernels
2.4, 2.6, 2.6 hardened), PHP 5.03, 5.04, 4.3.7

In FreeBSD 5.3 there is no problem executing the script.

Reproduce code:
---
 

Expected result:

time with microseconds

Actual result:
--
When run from the command line - time with microseconds and words
"Segmentation fault",
when called from browser - no output.





-- 
Edit this bug report at http://bugs.php.net/?id=32742&edit=1


#32746 [NEW]: PHP command line option doesn't have verbose/debug output.

2005-04-18 Thread scott at abcoa dot com
From: scott at abcoa dot com
Operating system: AIX or any Unix(s)/Linux(s)
PHP version:  4.3.10
PHP Bug Type: Unknown/Other Function
Bug description:  PHP command line option doesn't have verbose/debug output.

Description:

This is a request for enhancement for the command line option.   I
couldn't find an earlier bug report via bug search, so forgive me if this
is a duplicate or something.  As I looked up at
http://us2.php.net/features.commandline and it doesn't have the option for
debugging or verbose output via the shell environment.  

With most shell environment for bash, ksh, etc., I can do the -x or maybe
-d option to see the output via the O/S and I/O so I can see what is goign
on behind hte scene when I have problem with why am I not getting response.
 A line by line trace is useful also...

Yes, I can do with exec() or system() but I had cURL compiled with PHP and
other stuffs, so it get more complicated than it look.  Thanks...

Reproduce code:
---
#!/usr/local/bin/php


Expected result:

Something like this or close enough, whatever make it possible for us to
read the O/S output or I/O output...

--snip--
-=[/usr/local/bin]==>sh -x ./inquiry_pull_test.sh 
+ 0< l
+ = 
./inquiry_pull_test.sh[3]: =:  not found.
+ Testing Inquiry Send...
* About to connect() to ec.equifax.com:443
* Connected to ec.equifax.com ((nil)) port 443
* SSL connection using RC4-MD5
* Server certificate:
*subject: /C=US/ST=Georgia/L=Alpharetta/O=Equifax
Inc/CN=ec.equifax.com
*start date: 2004-07-01 02:57:28 GMT
*expire date: 2005-07-01 02:57:28 GMT
*common name: ec.equifax.com (matched)
*issuer: /C=ZA/ST=Western Cape/L=Cape Town/O=Thawte Consulting
cc/OU=Certification Services Division/CN=Thawte Server
CA/[EMAIL PROTECTED]
> POST /servlet/stspost HTTP/1.1
Authorization: Basic blah blah
OpenSSL/0.9.6g
Host: ec.equifax.com
Pragma: no-cache
Accept: image/gif, image/x-xbitmap, image/jpeg, image/pjpeg, */*
Content-Length: 396
Content-Type: application/x-www-form-urlencoded

site_id=0&service_name=test&efx_request=DIAL blah blah   
--snip--


-- 
Edit bug report at http://bugs.php.net/?id=32746&edit=1
-- 
Try a CVS snapshot (php4):   http://bugs.php.net/fix.php?id=32746&r=trysnapshot4
Try a CVS snapshot (php5.0): 
http://bugs.php.net/fix.php?id=32746&r=trysnapshot50
Try a CVS snapshot (php5.1): 
http://bugs.php.net/fix.php?id=32746&r=trysnapshot51
Fixed in CVS:http://bugs.php.net/fix.php?id=32746&r=fixedcvs
Fixed in release:http://bugs.php.net/fix.php?id=32746&r=alreadyfixed
Need backtrace:  http://bugs.php.net/fix.php?id=32746&r=needtrace
Need Reproduce Script:   http://bugs.php.net/fix.php?id=32746&r=needscript
Try newer version:   http://bugs.php.net/fix.php?id=32746&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=32746&r=support
Expected behavior:   http://bugs.php.net/fix.php?id=32746&r=notwrong
Not enough info: 
http://bugs.php.net/fix.php?id=32746&r=notenoughinfo
Submitted twice: 
http://bugs.php.net/fix.php?id=32746&r=submittedtwice
register_globals:http://bugs.php.net/fix.php?id=32746&r=globals
PHP 3 support discontinued:  http://bugs.php.net/fix.php?id=32746&r=php3
Daylight Savings:http://bugs.php.net/fix.php?id=32746&r=dst
IIS Stability:   http://bugs.php.net/fix.php?id=32746&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=32746&r=gnused
Floating point limitations:  http://bugs.php.net/fix.php?id=32746&r=float
No Zend Extensions:  http://bugs.php.net/fix.php?id=32746&r=nozend
MySQL Configuration Error:   http://bugs.php.net/fix.php?id=32746&r=mysqlcfg


#32745 [NEW]: Incorrect reassignemeent of $this error

2005-04-18 Thread jason at amp-design dot net
From: jason at amp-design dot net
Operating system: CentOS 3 / RHEL 3
PHP version:  5CVS-2005-04-18 (dev)
PHP Bug Type: Zend Engine 2 problem
Bug description:  Incorrect reassignemeent of $this error

Description:

An incorrect message about the reassignment of $this occurs in the 5.1.x
branches of PHP.

The code below doesn't product any errors...




but the "Reproduce code" produces an error when you are inside class
scope, trying to use the & operator to create a reference to $this.

Obviously the code $b = $this; does the exact same thing in PHP5, however
this is a problem as existing code (especially stuff written for PHP4 and
PHP5) will break. This is certainly the case here as this bug arises in
functions/imap_mailbox.php on line 25 of squirrel mail.

Please note this was tested using the php5-200504121430 build which is a
couple of days old now. I'm pretty sure it will remain in the latest
snapshot.

I have no idea why this comes up with the "reassigment of $this" error. I
would have thought this error would happen if the expression was reversed
to say $this = &$b.

Reproduce code:
---
test();
?>

Expected result:

No output. $a is created and $b === $a during the scope of A::test() for
the given code above.

Actual result:
--
Fatal error: Cannot re-assign $this in /var/www/html/test.php on line 4

-- 
Edit bug report at http://bugs.php.net/?id=32745&edit=1
-- 
Try a CVS snapshot (php4):   http://bugs.php.net/fix.php?id=32745&r=trysnapshot4
Try a CVS snapshot (php5.0): 
http://bugs.php.net/fix.php?id=32745&r=trysnapshot50
Try a CVS snapshot (php5.1): 
http://bugs.php.net/fix.php?id=32745&r=trysnapshot51
Fixed in CVS:http://bugs.php.net/fix.php?id=32745&r=fixedcvs
Fixed in release:http://bugs.php.net/fix.php?id=32745&r=alreadyfixed
Need backtrace:  http://bugs.php.net/fix.php?id=32745&r=needtrace
Need Reproduce Script:   http://bugs.php.net/fix.php?id=32745&r=needscript
Try newer version:   http://bugs.php.net/fix.php?id=32745&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=32745&r=support
Expected behavior:   http://bugs.php.net/fix.php?id=32745&r=notwrong
Not enough info: 
http://bugs.php.net/fix.php?id=32745&r=notenoughinfo
Submitted twice: 
http://bugs.php.net/fix.php?id=32745&r=submittedtwice
register_globals:http://bugs.php.net/fix.php?id=32745&r=globals
PHP 3 support discontinued:  http://bugs.php.net/fix.php?id=32745&r=php3
Daylight Savings:http://bugs.php.net/fix.php?id=32745&r=dst
IIS Stability:   http://bugs.php.net/fix.php?id=32745&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=32745&r=gnused
Floating point limitations:  http://bugs.php.net/fix.php?id=32745&r=float
No Zend Extensions:  http://bugs.php.net/fix.php?id=32745&r=nozend
MySQL Configuration Error:   http://bugs.php.net/fix.php?id=32745&r=mysqlcfg


#32427 [Asn]: Interfaces not allowed access modifiers

2005-04-18 Thread jason at amp-design dot net
 ID:   32427
 User updated by:  jason at amp-design dot net
 Reported By:  jason at amp-design dot net
 Status:   Assigned
 Bug Type: Zend Engine 2 problem
 Operating System: Cent OS 3
 PHP Version:  5CVS-2005-03-23 (dev)
 Assigned To:  andi
 New Comment:

It appears in the later CVS versions of PHP that this bug seems to have
gone. It appears to be fixed (maybe someone double check, and close it)


Previous Comments:


[2005-03-30 18:51:12] [EMAIL PROTECTED]

Assigning to Andi, as he's the author of this change:
http://cvs.php.net/diff.php/ZendEngine2/zend_compile.c?php=69434a7f33b2b7d3cc6152f95b1a307f&r1=1.596&r2=1.597&ty=u



[2005-03-23 13:27:27] jason at amp-design dot net

Description:

In the 5.1.0 branch (this morning's build), there seems to be a problem
with interfaces and static methods.

If a method is declared as static, it raises an error.

Upon removing the public static keywords from the interface, I get an
error because the class implementing this interface has a different
signature / declaraton from the interface, Thus meaning static members
are a no-no with interfaces.

This was tested on this morning's snapshot build of 5.1.0. I assume
that this is a bug and not some daft change in behavoiour you want to
push into the 5.1.x branch of PHP as it would break a lot of existing
PHP5 code.

Reproduce code:
---


Expected result:

I am a silly error

Actual result:
--
Fatal error: Access type for interface method Example::sillyError()
must be omitted in /data/web/tools/iq_framework/test.php on line 4





-- 
Edit this bug report at http://bugs.php.net/?id=32427&edit=1


#26495 [Asn->Opn]: Using WebSite Pro 2.5 with ISAPI, cookies are not working

2005-04-18 Thread wez
 ID:   26495
 Updated by:   [EMAIL PROTECTED]
 Reported By:  maura at fastwebnet dot it
-Status:   Assigned
+Status:   Open
 Bug Type: Other web server
 Operating System: win nt4 sp6a
 PHP Version:  5CVS, 4CVS
 Assigned To:  wez
 New Comment:

I already said that I don't have the time or inclination to do this.
I'm available for hire, should someone really needs it.


Previous Comments:


[2004-01-11 11:32:41] [EMAIL PROTECTED]

Assigned to the only person who knows what's going on here.




[2003-12-02 01:44:23] [EMAIL PROTECTED]

Those two opcodes are MS specific ISAPI codes to determine
the webroot and send headers respectively.

Currently, our ISAPI module relies on the web server implementing those
opcodes.

It shouldn't be too difficult to use the traditional
HSE_REQ_SEND_RESPONSE_HEADER opcode as a fallback for
the latter code.

Speaking for myself, I don't have the time to do this,
but I don't expect it to take much more than an hour or
so to implement; maybe one of the other isapi guys
has the time?




[2003-12-01 20:03:04] maura at fastwebnet dot it

Description:

I use O'Reilly WebSite Pro 2.5 and php4isapi.dll

All is working but no cookies are sent to browser.

Changes made in php.ini-recommended are:
doc_root = "c:\webroot"


Reproduce code:
---


Expected result:

That cookie is sent to the browser

Actual result:
--
server.log report:

** REQUEST from 192.168.0.1 **
REQ: m=GET u=/prova/provaphp.php a= p= 
Accept: image/gif, image/x-xbitmap, image/jpeg, image/pjpeg,
application/vnd.ms-excel, application/msword,
application/vnd.ms-powerpoint, */*
Accept-Language: en-us
Accept-Encoding: gzip, deflate
User-Agent: Mozilla/4.0 (compatible; MSIE 5.5; Windows NT 4.0)
Host: www.mysite.net
Connection: Keep-Alive
Cookie: userid=maurissia; passw=maurissia;
w=110099120118110121122113106

Request decoding complete...
node=C:/Siti/Mokadom/prova/provaphp.php: params= args=
Calling ISAPI/ISA C:\PHP\sapi\php4isapi.dll
[ISAPI] url  "/prova/provaphp.php"
[ISAPI] args ""
Associated ISA, using bogus MS path info
ISAPI: ServerSupportFunction() called with unknown opcode 1012
ISAPI: ServerSupportFunction() called with unknown opcode 1016





-- 
Edit this bug report at http://bugs.php.net/?id=26495&edit=1


#32026 [Opn->Fbk]: Can't call to function with paramArray in arg list definition

2005-04-18 Thread wez
 ID:   32026
 Updated by:   [EMAIL PROTECTED]
 Reported By:  csaba at alum dot mit dot edu
-Status:   Open
+Status:   Feedback
 Bug Type: COM related
 Operating System: Win XP Pro
 PHP Version:  5CVS-2005-02-19
 New Comment:

Please paste the IDL for that method into this bug report.
You can view the IDL using the OleView tool.


Previous Comments:


[2005-02-19 11:09:13] csaba at alum dot mit dot edu

Description:

If I try to make a call to a function where the function has a
paramArray (a VB construct) in the definition, the call fails with (if
the param array gets at least one argument).

For the unfamiliar, a paramArray in VB is an array (of variants) which
consists of all the remaining arguments to the procedure.  As such, it
must be the last declared parameter in the Function declaration.

Csaba Gabor from Vienna


Reproduce code:
---
Here is the PHP test code (menu.php):
ArgCount ("junk", 5, 13);
print $result;
?>


Here is the code for the Menu.OCX file:
Public Function ArgCount(Arg1, ParamArray paArgRest())
'counts the number of arguments passed, excluding Arg1
ArgCount = UBound(paArgRest) + 1 - LBound(paArgRest)
End Function

Notes:
This was built using VB5CCE (the free (while available) VB, Control
Creation Edition)
I have named my control Tool
I have named the Project Menu
I made the OCX into Menu.ocx
In the (VB5CCE) project I went to Project => Menu Properties =>
Component tab and set No Compatibility
After I made Menu.OCX, from the directory Menu.ocx resides in, I did:
regsvr32 Menu.ocx


Here is the corresponding VBScript test file (menu.vbs) that works:
Set oTool = CreateObject("Menu.Tool")
result = oTool.ArgCount("junk", 5, 13)
MsgBox result

Expected result:

I expect to see a 2 printed or displayed (since there are two arguments
after "junk")

Actual result:
--
menu.vbs produces the expected 2.

menu.php file fails with:
Cannot pass parameter 2 by reference in C:\Testing\ParamArray\menu.php
on line 3

If the paramArray gets no elements
$result = $oTool->ArgCount ("junk");
then I get the expected 0

I've inserted a
com_print_typeinfo($oTool) and received (there was other code in
menu.ocx):
/* DISPID=1610809344 */
/* VT_VARIANT [12] */
function ArgCount(
/* VT_PTR [26] [in][out] --> VT_VARIANT [12]  */
&$Arg1,
/* VT_PTR [26] [in][out] --> ? [27]  */ &$paArgRest
)
{
}





-- 
Edit this bug report at http://bugs.php.net/?id=32026&edit=1


#32748 [NEW]: Open file error when opening in browser

2005-04-18 Thread graduate_fall_2003 at yahoo dot co dot in
From: graduate_fall_2003 at yahoo dot co dot in
Operating system: WIndows XP
PHP version:  4.3.11
PHP Bug Type: Apache related
Bug description:  Open file error when opening in browser

Description:

I am a beginner and just installed PHP 4.3.11 and Apache 1.3.33 using the
instructions and faq's. I configured Php as a CGI in the apache web
server.

Everytime i open the phpinfo.php file in the web browser, it show me the
Open, save window. Also it does not show Php in the registry..
HKEY_LOCAL_MAchine/ software.

I have installed php and apache on my D:

Please help me.

Thank you

Expected result:

It show show me a table with all the system variables in it.

Actual result:
--
it opens the window for download file

-- 
Edit bug report at http://bugs.php.net/?id=32748&edit=1
-- 
Try a CVS snapshot (php4):   http://bugs.php.net/fix.php?id=32748&r=trysnapshot4
Try a CVS snapshot (php5.0): 
http://bugs.php.net/fix.php?id=32748&r=trysnapshot50
Try a CVS snapshot (php5.1): 
http://bugs.php.net/fix.php?id=32748&r=trysnapshot51
Fixed in CVS:http://bugs.php.net/fix.php?id=32748&r=fixedcvs
Fixed in release:http://bugs.php.net/fix.php?id=32748&r=alreadyfixed
Need backtrace:  http://bugs.php.net/fix.php?id=32748&r=needtrace
Need Reproduce Script:   http://bugs.php.net/fix.php?id=32748&r=needscript
Try newer version:   http://bugs.php.net/fix.php?id=32748&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=32748&r=support
Expected behavior:   http://bugs.php.net/fix.php?id=32748&r=notwrong
Not enough info: 
http://bugs.php.net/fix.php?id=32748&r=notenoughinfo
Submitted twice: 
http://bugs.php.net/fix.php?id=32748&r=submittedtwice
register_globals:http://bugs.php.net/fix.php?id=32748&r=globals
PHP 3 support discontinued:  http://bugs.php.net/fix.php?id=32748&r=php3
Daylight Savings:http://bugs.php.net/fix.php?id=32748&r=dst
IIS Stability:   http://bugs.php.net/fix.php?id=32748&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=32748&r=gnused
Floating point limitations:  http://bugs.php.net/fix.php?id=32748&r=float
No Zend Extensions:  http://bugs.php.net/fix.php?id=32748&r=nozend
MySQL Configuration Error:   http://bugs.php.net/fix.php?id=32748&r=mysqlcfg


#29583 [Asn->Csd]: [PATCH] com_dotnet crashes when trying to strlen

2005-04-18 Thread wez
 ID:   29583
 Updated by:   [EMAIL PROTECTED]
 Reported By:  edwin at rabbito dot org
-Status:   Assigned
+Status:   Closed
 Bug Type: COM related
 Operating System: Windows
 PHP Version:  5CVS-2005-02-15
 Assigned To:  wez
 New Comment:

This bug has been fixed in CVS.

Snapshots of the sources are packaged every three hours; this change
will be in the next snapshot. You can grab the snapshot at
http://snaps.php.net/.
 
Thank you for the report, and for helping us make PHP better.

Committed at last.


Previous Comments:


[2005-03-25 01:26:44] [EMAIL PROTECTED]

See also bug #31636




[2005-03-25 01:24:44] [EMAIL PROTECTED]

Wez, there's even a patch in this one..




[2005-02-15 15:23:40] edwin at rabbito dot org

Works after applying "msisolak at yahoo dot com"'s patch on latest CVS



[2005-02-15 00:26:40] [EMAIL PROTECTED]

Please try using this CVS snapshot:

  http://snaps.php.net/php5-STABLE-latest.tar.gz
 
For Windows:
 
  http://snaps.php.net/win32/php5.0-win32-latest.zip





[2004-09-02 21:00:44] msisolak at yahoo dot com

I've dug into the COM error reported here and believe I have discovered
the issue.  The problem is that com_object_cast() (in com_handlers.c)
assumes that the readobj and writeobj parameters will never be the same
object.  That appears to work fine, except when the type conversion
request comes from the convert_object_to_type() macro
(zend_operators.c, line 264).  In this case readobj == writeobj and we
end up with an access violation.  Since _convert_to_string() uses
convert_object_to_type(), and _convert_to_string() is used when you try
to strlen() an object, com_object_cast() fails in the code from this bug
report.

Based on using sxe_object_cast() from the SimpleXML extension as a
example, I think that the freeing of the writeobj needs to be the last
thing done in the function rather than the first.  The attached patch
uses that function as a model to move the zval_dtor() call to the end. 
I also feel that the ZVAL_NULL(writeobj) should move after the
CDNO_FETCH(readobj).  It seems to work as is, but only becuase
CDNO_FETCH() isn't checking that what is passed to it is really an
object.

I've played with this patch some and it seems to be holding, but I'm
looking at this with limited understanding of how the objects are
really being passed around so there may be an interaction here I'm not
seeing.  With the patch applied, this PHP code:

echo strlen($rs->Fields(0)->Value), "\n";
echo date("F j, Y", variant_date_to_timestamp($rs->Fields(0)->Value)),
"\n";
echo date("F j, Y", variant_date_to_timestamp($rs->Fields(0))), "\n";
echo $rs->Fields(0)->Value, "\n";
echo $rs->Fields(0), "\n";

returns correct values in all five cases (for my test database):

8
January 1, 2001
January 1, 2001
1/1/2001
1/1/2001



--- php-5.0.1\ext\com_dotnet\com_handlers.c Wed Jul 28 19:48:26 2004
+++ com_handlers.c  Thu Aug 19 15:18:45 2004
@@ -521,17 +521,17 @@
 
 static int com_object_cast(zval *readobj, zval *writeobj, int type, 
int should_free TSRMLS_DC)
 {
+   zval free_obj;
php_com_dotnet_object *obj;
VARIANT v;
VARTYPE vt = VT_EMPTY;
 
if (should_free) {
-   zval_dtor(writeobj);
+   free_obj = *writeobj;
}
 
-   ZVAL_NULL(writeobj);
-
obj = CDNO_FETCH(readobj);
+   ZVAL_NULL(writeobj);
VariantInit(&v);
 
if (V_VT(&obj->v) == VT_DISPATCH) {
@@ -569,6 +569,9 @@
 
php_com_zval_from_variant(writeobj, &v, obj->code_page TSRMLS_CC);
VariantClear(&v);
+   if (should_free) {
+   zval_dtor(&free_obj);
+   }
return SUCCESS;
 }



The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/29583

-- 
Edit this bug report at http://bugs.php.net/?id=29583&edit=1


#32038 [Opn->WFx]: com_print_typeinfo returning duplicate entries

2005-04-18 Thread wez
 ID:   32038
 Updated by:   [EMAIL PROTECTED]
 Reported By:  csaba at alum dot mit dot edu
-Status:   Open
+Status:   Wont fix
 Bug Type: COM related
 Operating System: Win XP Pro
 PHP Version:  5CVS-2005-02-20
 New Comment:

that function is mainly a debugging aid; all it does is walk through
the list of available items in the type info.
The "duplicates" are present because the type info stores one record
for get and another for set when dealing with properties.
While this function could be made smarter, I don't plan to do so; it
just doesn't need to be made that complicated.


Previous Comments:


[2005-02-20 22:45:25] csaba at alum dot mit dot edu

Description:

com_print_typeinfo is often showing duplicate entries for many of the
properties of various COM objects, for example: IWebBrowser2

Reproduce code:
---
Windows();
foreach ($oWins as $oWin) {
com_print_typeinfo($oWin,"IWebBrowser2");
break; }
?>

Expected result:

I expect each property to be listed exactly once

Actual result:
--
Here's part of the printout:
/* DISPID=555 */
/* VT_BOOL [11] */
/* Controls whether address bar is shown */
var $AddressBar;

/* DISPID=555 */
/* Controls whether address bar is shown */
var $AddressBar;

/* DISPID=556 */
/* VT_BOOL [11] */
/* Controls whether the window is resizable */
var $Resizable;

/* DISPID=556 */
/* Controls whether the window is resizable */
var $Resizable;


As you can see, both properties are shown twice.  The first of the two
showings always shows the variant type (e.g.  VT_BOOL [11]) whereas the
second does not.  It seems superfluous to have these shown twice
(especially since the printouts are so voluminous and the second is a
subset of the first).  I have not seen this happen with Methods.

Csaba Gabor from Vienna





-- 
Edit this bug report at http://bugs.php.net/?id=32038&edit=1


#31636 [Asn->Csd]: Type cast is unchecked

2005-04-18 Thread wez
 ID:   31636
 Updated by:   [EMAIL PROTECTED]
 Reported By:  ivar at stvk dot no
-Status:   Assigned
+Status:   Closed
 Bug Type: COM related
 Operating System: Windows XP
 PHP Version:  5.0.3
 Assigned To:  wez
 New Comment:

This bug has been fixed in CVS.

Snapshots of the sources are packaged every three hours; this change
will be in the next snapshot. You can grab the snapshot at
http://snaps.php.net/.
 
Thank you for the report, and for helping us make PHP better.




Previous Comments:


[2005-02-06 04:01:56] fsleng at supmano dot sk

This seems to be related to Bug#29583 (com_dotnet crashes when trying
to strlen).



[2005-01-26 11:15:08] [EMAIL PROTECTED]

Wez, could you have a look?



[2005-01-23 18:05:50] ivar at stvk dot no

There seems to be a misconception in the COM code that a IDispatch
variable with VARDESC.wVarFlags = VARFLAG_FDEFAULTBIND is the value to
return as the object's default value. Default binding is used as a flag
on ActiveX Control Properties to tell which control property that is to
be bound to a datasource. This kind of binding may be either a variable
(VARDESC) or a function (FUNCDESC).

The code looks like the programmer has intended to fetch the objects
default value. This value is by OLE Automation defined as having DISPID
= DISPID_VALUE. 

com_write_dimension and com_read_dimension should be rewritten to call
php_com_do_invoke_by_id using DISPID_VALUE.

com_object_cast should be rewritten to use VariantChangeType directly
to do the cast:

static int com_object_cast(zval *readobj, zval *writeobj, int type, int
should_free TSRMLS_DC)
{
php_com_dotnet_object *obj;
VARIANT v;
VARTYPE vt = VT_EMPTY;
int ret;
HRESULT hr;

if (should_free) {
zval_dtor(writeobj);
}

ZVAL_NULL(writeobj);

obj = CDNO_FETCH(readobj);
VariantInit(&v);

switch(type) {
case IS_LONG:
vt = VT_INT;
break;
case IS_DOUBLE:
vt = VT_R8;
break;
case IS_BOOL:
vt = VT_BOOL;
break;
case IS_STRING:
vt = VT_BSTR;
break;
default:
return FAILURE;
}

if (FAILED(hr=VariantChangeType(&v, &obj->v, 0, vt))) {
return FAILURE;
}

ret = php_com_zval_from_variant(writeobj, &v, obj->code_page
TSRMLS_CC);
VariantClear(&v);
return ret;
}

This also makes com_object_cast to obey the rule of returning FAILURE
if it is unable to return the required zval type.



[2005-01-21 15:25:09] ivar at stvk dot no

Description:

com_object_cast is at least called by zend_make_printable_zval. In this
context, it appears that the contract of the handler is to return a zval
with the the specified type. If not able to return the value, it should
return FAILURE.

The handler will return a valid zval with wrong type if
VariantChangeType fails, or if the requested cast type is not
supported.






-- 
Edit this bug report at http://bugs.php.net/?id=31636&edit=1


#32745 [Opn->Bgs]: Incorrect reassignemeent of $this error

2005-04-18 Thread johannes
 ID:   32745
 Updated by:   [EMAIL PROTECTED]
 Reported By:  jason at amp-design dot net
-Status:   Open
+Status:   Bogus
 Bug Type: Zend Engine 2 problem
 Operating System: CentOS 3 / RHEL 3
 PHP Version:  5CVS-2005-04-18 (dev)
 New Comment:

Thank you for taking the time to write to us, but this is not
a bug. Please double-check the documentation available at
http://www.php.net/manual/ and the instructions on how to report
a bug at http://bugs.php.net/how-to-report.php

$b = $this already creates an object-reference to $this. 
If you do a $b = &$this PHP couldn't detect that $b is the 
same as $this, that could be overwritten and this would 
lead to problems with the engine. 


Previous Comments:


[2005-04-18 17:45:56] jason at amp-design dot net

Description:

An incorrect message about the reassignment of $this occurs in the
5.1.x branches of PHP.

The code below doesn't product any errors...




but the "Reproduce code" produces an error when you are inside class
scope, trying to use the & operator to create a reference to $this.

Obviously the code $b = $this; does the exact same thing in PHP5,
however this is a problem as existing code (especially stuff written
for PHP4 and PHP5) will break. This is certainly the case here as this
bug arises in functions/imap_mailbox.php on line 25 of squirrel mail.

Please note this was tested using the php5-200504121430 build which is
a couple of days old now. I'm pretty sure it will remain in the latest
snapshot.

I have no idea why this comes up with the "reassigment of $this" error.
I would have thought this error would happen if the expression was
reversed to say $this = &$b.

Reproduce code:
---
test();
?>

Expected result:

No output. $a is created and $b === $a during the scope of A::test()
for the given code above.

Actual result:
--
Fatal error: Cannot re-assign $this in /var/www/html/test.php on line 4





-- 
Edit this bug report at http://bugs.php.net/?id=32745&edit=1


#32749 [NEW]: shm_put_var/shm_get_var does not work on objects with __sleep defined

2005-04-18 Thread cr at speedofmind dot com
From: cr at speedofmind dot com
Operating system: Linux 2.4.26
PHP version:  5.0.3
PHP Bug Type: Zend Engine 2 problem
Bug description:  shm_put_var/shm_get_var does not work on objects with __sleep 
defined

Description:

When defining a __sleep funtion in a class, it is not possible to
successfully save and retrieve objects of this class using shm_put_var and
shm_get_var. shm_get_var simple returns NULL.

Reproduce code:
---
kind = $kind; }
function __wakeup() { $this->foo = 'bar1'; }
function __sleep() { $this->foo = 'bar2'; } // BREAKS
shm_put_var/shm_get_var 
}

$var = new Fruit('apple');
$key = 1;

$shmId = shm_attach(24187);
shm_put_var($shmId, $key, $var);
$out = shm_get_var($shmId, $key);  

var_dump($out);

?>

Expected result:

Expected output:

object(Fruit)#2 (2) {
  ["kind"]=>
  string(5) "apple"
  ["foo"]=>
  string(4) "bar1"
}

Actual result:
--
Actual output:

NULL

-- 
Edit bug report at http://bugs.php.net/?id=32749&edit=1
-- 
Try a CVS snapshot (php4):   http://bugs.php.net/fix.php?id=32749&r=trysnapshot4
Try a CVS snapshot (php5.0): 
http://bugs.php.net/fix.php?id=32749&r=trysnapshot50
Try a CVS snapshot (php5.1): 
http://bugs.php.net/fix.php?id=32749&r=trysnapshot51
Fixed in CVS:http://bugs.php.net/fix.php?id=32749&r=fixedcvs
Fixed in release:http://bugs.php.net/fix.php?id=32749&r=alreadyfixed
Need backtrace:  http://bugs.php.net/fix.php?id=32749&r=needtrace
Need Reproduce Script:   http://bugs.php.net/fix.php?id=32749&r=needscript
Try newer version:   http://bugs.php.net/fix.php?id=32749&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=32749&r=support
Expected behavior:   http://bugs.php.net/fix.php?id=32749&r=notwrong
Not enough info: 
http://bugs.php.net/fix.php?id=32749&r=notenoughinfo
Submitted twice: 
http://bugs.php.net/fix.php?id=32749&r=submittedtwice
register_globals:http://bugs.php.net/fix.php?id=32749&r=globals
PHP 3 support discontinued:  http://bugs.php.net/fix.php?id=32749&r=php3
Daylight Savings:http://bugs.php.net/fix.php?id=32749&r=dst
IIS Stability:   http://bugs.php.net/fix.php?id=32749&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=32749&r=gnused
Floating point limitations:  http://bugs.php.net/fix.php?id=32749&r=float
No Zend Extensions:  http://bugs.php.net/fix.php?id=32749&r=nozend
MySQL Configuration Error:   http://bugs.php.net/fix.php?id=32749&r=mysqlcfg


#32749 [Opn]: shm_put_var/shm_get_var does not work on objects with __sleep defined

2005-04-18 Thread cr at speedofmind dot com
 ID:   32749
 User updated by:  cr at speedofmind dot com
 Reported By:  cr at speedofmind dot com
 Status:   Open
 Bug Type: Zend Engine 2 problem
 Operating System: Linux 2.4.26
 PHP Version:  5.0.3
 New Comment:

Reproducable code again:

kind = $kind; }
function __wakeup() { $this->foo = 'bar1'; }
function __sleep() { $this->foo = 'bar2'; } // BREAKS
shm_put_var/shm_get_var 
}

$var = new Fruit('apple');
$key = 1;

$shmId = shm_attach(24187);
shm_put_var($shmId, $key, $var);
$out = shm_get_var($shmId, $key);  

var_dump($out);

?>


Previous Comments:


[2005-04-18 20:38:03] cr at speedofmind dot com

Description:

When defining a __sleep funtion in a class, it is not possible to
successfully save and retrieve objects of this class using shm_put_var
and shm_get_var. shm_get_var simple returns NULL.

Reproduce code:
---
kind = $kind; }
function __wakeup() { $this->foo = 'bar1'; }
function __sleep() { $this->foo = 'bar2'; } // BREAKS
shm_put_var/shm_get_var 
}

$var = new Fruit('apple');
$key = 1;

$shmId = shm_attach(24187);
shm_put_var($shmId, $key, $var);
$out = shm_get_var($shmId, $key);  

var_dump($out);

?>

Expected result:

Expected output:

object(Fruit)#2 (2) {
  ["kind"]=>
  string(5) "apple"
  ["foo"]=>
  string(4) "bar1"
}

Actual result:
--
Actual output:

NULL





-- 
Edit this bug report at http://bugs.php.net/?id=32749&edit=1


#32749 [Opn]: shm_put_var/shm_get_var does not work on objects with __sleep defined

2005-04-18 Thread cr at speedofmind dot com
 ID:   32749
 User updated by:  cr at speedofmind dot com
 Reported By:  cr at speedofmind dot com
 Status:   Open
 Bug Type: Zend Engine 2 problem
 Operating System: Linux 2.4.26
 PHP Version:  5.0.3
 New Comment:

Seems your Bug system chokes on PHP-tags in the submitted code. Here's
the code without surrounding PHP-tags:

class Fruit {
var $kind;
var $foo = 'not';
function Fruit($kind) { $this->kind = $kind; }
function __wakeup() { $this->foo = 'bar1'; }
function __sleep() { $this->foo = 'bar2'; } // BREAKS
shm_put_var/shm_get_var 
}

$var = new Fruit('apple');
$key = 1;

$shmId = shm_attach(24187);
shm_put_var($shmId, $key, $var);
$out = shm_get_var($shmId, $key);  

var_dump($out);


Previous Comments:


[2005-04-18 20:39:26] cr at speedofmind dot com

Reproducable code again:

kind = $kind; }
function __wakeup() { $this->foo = 'bar1'; }
function __sleep() { $this->foo = 'bar2'; } // BREAKS
shm_put_var/shm_get_var 
}

$var = new Fruit('apple');
$key = 1;

$shmId = shm_attach(24187);
shm_put_var($shmId, $key, $var);
$out = shm_get_var($shmId, $key);  

var_dump($out);

?>



[2005-04-18 20:38:03] cr at speedofmind dot com

Description:

When defining a __sleep funtion in a class, it is not possible to
successfully save and retrieve objects of this class using shm_put_var
and shm_get_var. shm_get_var simple returns NULL.

Reproduce code:
---
kind = $kind; }
function __wakeup() { $this->foo = 'bar1'; }
function __sleep() { $this->foo = 'bar2'; } // BREAKS
shm_put_var/shm_get_var 
}

$var = new Fruit('apple');
$key = 1;

$shmId = shm_attach(24187);
shm_put_var($shmId, $key, $var);
$out = shm_get_var($shmId, $key);  

var_dump($out);

?>

Expected result:

Expected output:

object(Fruit)#2 (2) {
  ["kind"]=>
  string(5) "apple"
  ["foo"]=>
  string(4) "bar1"
}

Actual result:
--
Actual output:

NULL





-- 
Edit this bug report at http://bugs.php.net/?id=32749&edit=1


#32748 [Opn->Bgs]: Open file error when opening in browser

2005-04-18 Thread derick
 ID:   32748
 Updated by:   [EMAIL PROTECTED]
 Reported By:  graduate_fall_2003 at yahoo dot co dot in
-Status:   Open
+Status:   Bogus
 Bug Type: Apache related
 Operating System: WIndows XP
 PHP Version:  4.3.11
 New Comment:

Sorry, but your problem does not imply a bug in PHP itself.  For a
list of more appropriate places to ask for help using PHP, please
visit http://www.php.net/support.php as this bug system is not the
appropriate forum for asking support questions.  Due to the volume
of reports we can not explain in detail here why your report is not
a bug.  The support channels will be able to provide an explanation
for you.

Thank you for your interest in PHP.

.


Previous Comments:


[2005-04-18 18:29:19] graduate_fall_2003 at yahoo dot co dot in

Description:

I am a beginner and just installed PHP 4.3.11 and Apache 1.3.33 using
the instructions and faq's. I configured Php as a CGI in the apache web
server.

Everytime i open the phpinfo.php file in the web browser, it show me
the Open, save window. Also it does not show Php in the registry..
HKEY_LOCAL_MAchine/ software.

I have installed php and apache on my D:

Please help me.

Thank you

Expected result:

It show show me a table with all the system variables in it.

Actual result:
--
it opens the window for download file





-- 
Edit this bug report at http://bugs.php.net/?id=32748&edit=1


#32743 [Opn->Bgs]: Error with type of 2nd parameter when creating DOMDocument()

2005-04-18 Thread chregu
 ID:   32743
 Updated by:   [EMAIL PROTECTED]
 Reported By:  jj at intelequest dot com
-Status:   Open
+Status:   Bogus
 Bug Type: DOM XML related
 Operating System: Windows XP
 PHP Version:  5.0.4
 New Comment:

Looks like you're testing that against PHP 4.3.

I get exactly your error with PHP 4.3, but not with PHP 5...


Previous Comments:


[2005-04-18 16:44:05] jj at intelequest dot com

The reproduce code is as follows:

$dom = new DOMDocument('1.0', 'iso-8859-1');
echo $dom->saveXML();



[2005-04-18 16:27:58] jj at intelequest dot com

Description:

When executing the demo code found at
http://www.php.net/manual/en/function.dom-domdocument-construct.php I
obtain the error message.

"Warning: domdocument() expects parameter 2 to be long"

My understanding (from the online docs) is that the 2nd parameter is to
be of type string.

Also, according to the documentation, this is the php 5 replacment to
DOM_XML i.e. this is DOM XML. Note that there is no sub-category for
just DOM so the next logical place to put errors such as these would be
either DOM XML or Documentation bug.



Reproduce code:
---
saveXML();
?>



Expected result:



Actual result:
--
Warning: domdocument() expects parameter 2 to be long, string given in
C:\temp\test_xml.php on line 2

Fatal error: Call to undefined method domdocument::saveXML() in
C:\temp\test_xml.php on line 3





-- 
Edit this bug report at http://bugs.php.net/?id=32743&edit=1


#32743 [Bgs->Opn]: Error with type of 2nd parameter when creating DOMDocument()

2005-04-18 Thread jj at intelequest dot com
 ID:   32743
 User updated by:  jj at intelequest dot com
 Reported By:  jj at intelequest dot com
-Status:   Bogus
+Status:   Open
 Bug Type: DOM XML related
 Operating System: Windows XP
 PHP Version:  5.0.4
 New Comment:

Sorry .. testing with 5.0.4.

PHP 5.0.4 (cli) (built: Mar 31 2005 02:45:48)
Copyright (c) 1997-2004 The PHP Group
Zend Engine v2.0.4-dev, Copyright (c) 1998-2004 Zend Technologies
with Zend Extension Manager v1.0.7, Copyright (c) 2003-2004, by
Zend Technologies
with Zend Optimizer v2.5.8, Copyright (c) 1998-2004, by Zend
Technologies
with Zend Debugger v4.0.0, Copyright (c) 1999-2005, by Zend
Technologies


Previous Comments:


[2005-04-18 20:51:30] [EMAIL PROTECTED]

Looks like you're testing that against PHP 4.3.

I get exactly your error with PHP 4.3, but not with PHP 5...



[2005-04-18 16:44:05] jj at intelequest dot com

The reproduce code is as follows:

$dom = new DOMDocument('1.0', 'iso-8859-1');
echo $dom->saveXML();



[2005-04-18 16:27:58] jj at intelequest dot com

Description:

When executing the demo code found at
http://www.php.net/manual/en/function.dom-domdocument-construct.php I
obtain the error message.

"Warning: domdocument() expects parameter 2 to be long"

My understanding (from the online docs) is that the 2nd parameter is to
be of type string.

Also, according to the documentation, this is the php 5 replacment to
DOM_XML i.e. this is DOM XML. Note that there is no sub-category for
just DOM so the next logical place to put errors such as these would be
either DOM XML or Documentation bug.



Reproduce code:
---
saveXML();
?>



Expected result:



Actual result:
--
Warning: domdocument() expects parameter 2 to be long, string given in
C:\temp\test_xml.php on line 2

Fatal error: Call to undefined method domdocument::saveXML() in
C:\temp\test_xml.php on line 3





-- 
Edit this bug report at http://bugs.php.net/?id=32743&edit=1


#32743 [Opn->Bgs]: Error with type of 2nd parameter when creating DOMDocument()

2005-04-18 Thread derick
 ID:   32743
 Updated by:   [EMAIL PROTECTED]
 Reported By:  jj at intelequest dot com
-Status:   Open
+Status:   Bogus
 Bug Type: DOM XML related
 Operating System: Windows XP
 PHP Version:  5.0.4
 New Comment:

Do not file bugs when you have Zend extensions (zend_extension=)
loaded. Examples are Zend Optimizer, Zend Debugger, Turck MM Cache,
APC, Xdebug and ionCube loader.  These extensions often modify engine
behavior which is not related to PHP itself.




Previous Comments:


[2005-04-18 21:11:57] jj at intelequest dot com

Sorry .. testing with 5.0.4.

PHP 5.0.4 (cli) (built: Mar 31 2005 02:45:48)
Copyright (c) 1997-2004 The PHP Group
Zend Engine v2.0.4-dev, Copyright (c) 1998-2004 Zend Technologies
with Zend Extension Manager v1.0.7, Copyright (c) 2003-2004, by
Zend Technologies
with Zend Optimizer v2.5.8, Copyright (c) 1998-2004, by Zend
Technologies
with Zend Debugger v4.0.0, Copyright (c) 1999-2005, by Zend
Technologies



[2005-04-18 20:51:30] [EMAIL PROTECTED]

Looks like you're testing that against PHP 4.3.

I get exactly your error with PHP 4.3, but not with PHP 5...



[2005-04-18 16:44:05] jj at intelequest dot com

The reproduce code is as follows:

$dom = new DOMDocument('1.0', 'iso-8859-1');
echo $dom->saveXML();



[2005-04-18 16:27:58] jj at intelequest dot com

Description:

When executing the demo code found at
http://www.php.net/manual/en/function.dom-domdocument-construct.php I
obtain the error message.

"Warning: domdocument() expects parameter 2 to be long"

My understanding (from the online docs) is that the 2nd parameter is to
be of type string.

Also, according to the documentation, this is the php 5 replacment to
DOM_XML i.e. this is DOM XML. Note that there is no sub-category for
just DOM so the next logical place to put errors such as these would be
either DOM XML or Documentation bug.



Reproduce code:
---
saveXML();
?>



Expected result:



Actual result:
--
Warning: domdocument() expects parameter 2 to be long, string given in
C:\temp\test_xml.php on line 2

Fatal error: Call to undefined method domdocument::saveXML() in
C:\temp\test_xml.php on line 3





-- 
Edit this bug report at http://bugs.php.net/?id=32743&edit=1


#32743 [Bgs->Opn]: Error with type of 2nd parameter when creating DOMDocument()

2005-04-18 Thread jj at intelequest dot com
 ID:   32743
 User updated by:  jj at intelequest dot com
 Reported By:  jj at intelequest dot com
-Status:   Bogus
+Status:   Open
 Bug Type: DOM XML related
 Operating System: Windows XP
 PHP Version:  5.0.4
 New Comment:

k .. 

took out zend extensions .. 

C:\temp>php -v
PHP 5.0.4 (cli) (built: Mar 31 2005 02:45:48)
Copyright (c) 1997-2004 The PHP Group
Zend Engine v2.0.4-dev, Copyright (c) 1998-2004 Zend Technologies

C:\temp>php test_xml.php

Warning: domdocument() expects parameter 2 to be long, string given in
C:\temp\test_xml.php on line 3

Fatal error: Call to undefined method domdocument::saveXML() in
C:\temp\test_xml.php on line 4


still gives an error ..


Previous Comments:


[2005-04-18 21:14:35] [EMAIL PROTECTED]

Do not file bugs when you have Zend extensions (zend_extension=)
loaded. Examples are Zend Optimizer, Zend Debugger, Turck MM Cache,
APC, Xdebug and ionCube loader.  These extensions often modify engine
behavior which is not related to PHP itself.





[2005-04-18 21:11:57] jj at intelequest dot com

Sorry .. testing with 5.0.4.

PHP 5.0.4 (cli) (built: Mar 31 2005 02:45:48)
Copyright (c) 1997-2004 The PHP Group
Zend Engine v2.0.4-dev, Copyright (c) 1998-2004 Zend Technologies
with Zend Extension Manager v1.0.7, Copyright (c) 2003-2004, by
Zend Technologies
with Zend Optimizer v2.5.8, Copyright (c) 1998-2004, by Zend
Technologies
with Zend Debugger v4.0.0, Copyright (c) 1999-2005, by Zend
Technologies



[2005-04-18 20:51:30] [EMAIL PROTECTED]

Looks like you're testing that against PHP 4.3.

I get exactly your error with PHP 4.3, but not with PHP 5...



[2005-04-18 16:44:05] jj at intelequest dot com

The reproduce code is as follows:

$dom = new DOMDocument('1.0', 'iso-8859-1');
echo $dom->saveXML();



[2005-04-18 16:27:58] jj at intelequest dot com

Description:

When executing the demo code found at
http://www.php.net/manual/en/function.dom-domdocument-construct.php I
obtain the error message.

"Warning: domdocument() expects parameter 2 to be long"

My understanding (from the online docs) is that the 2nd parameter is to
be of type string.

Also, according to the documentation, this is the php 5 replacment to
DOM_XML i.e. this is DOM XML. Note that there is no sub-category for
just DOM so the next logical place to put errors such as these would be
either DOM XML or Documentation bug.



Reproduce code:
---
saveXML();
?>



Expected result:



Actual result:
--
Warning: domdocument() expects parameter 2 to be long, string given in
C:\temp\test_xml.php on line 2

Fatal error: Call to undefined method domdocument::saveXML() in
C:\temp\test_xml.php on line 3





-- 
Edit this bug report at http://bugs.php.net/?id=32743&edit=1


#32743 [Opn->Bgs]: Error with type of 2nd parameter when creating DOMDocument()

2005-04-18 Thread jj at intelequest dot com
 ID:   32743
 User updated by:  jj at intelequest dot com
 Reported By:  jj at intelequest dot com
-Status:   Open
+Status:   Bogus
 Bug Type: DOM XML related
 Operating System: Windows XP
 PHP Version:  5.0.4
 New Comment:

My bad folks 

extension=php_domxml.dll 

was still active and caused this issue.

I apologize for the wasted time. =(


Previous Comments:


[2005-04-18 21:18:30] jj at intelequest dot com

k .. 

took out zend extensions .. 

C:\temp>php -v
PHP 5.0.4 (cli) (built: Mar 31 2005 02:45:48)
Copyright (c) 1997-2004 The PHP Group
Zend Engine v2.0.4-dev, Copyright (c) 1998-2004 Zend Technologies

C:\temp>php test_xml.php

Warning: domdocument() expects parameter 2 to be long, string given in
C:\temp\test_xml.php on line 3

Fatal error: Call to undefined method domdocument::saveXML() in
C:\temp\test_xml.php on line 4


still gives an error ..



[2005-04-18 21:14:35] [EMAIL PROTECTED]

Do not file bugs when you have Zend extensions (zend_extension=)
loaded. Examples are Zend Optimizer, Zend Debugger, Turck MM Cache,
APC, Xdebug and ionCube loader.  These extensions often modify engine
behavior which is not related to PHP itself.





[2005-04-18 21:11:57] jj at intelequest dot com

Sorry .. testing with 5.0.4.

PHP 5.0.4 (cli) (built: Mar 31 2005 02:45:48)
Copyright (c) 1997-2004 The PHP Group
Zend Engine v2.0.4-dev, Copyright (c) 1998-2004 Zend Technologies
with Zend Extension Manager v1.0.7, Copyright (c) 2003-2004, by
Zend Technologies
with Zend Optimizer v2.5.8, Copyright (c) 1998-2004, by Zend
Technologies
with Zend Debugger v4.0.0, Copyright (c) 1999-2005, by Zend
Technologies



[2005-04-18 20:51:30] [EMAIL PROTECTED]

Looks like you're testing that against PHP 4.3.

I get exactly your error with PHP 4.3, but not with PHP 5...



[2005-04-18 16:44:05] jj at intelequest dot com

The reproduce code is as follows:

$dom = new DOMDocument('1.0', 'iso-8859-1');
echo $dom->saveXML();



The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/32743

-- 
Edit this bug report at http://bugs.php.net/?id=32743&edit=1


#32743 [Bgs->Fbk]: Error with type of 2nd parameter when creating DOMDocument()

2005-04-18 Thread chregu
 ID:   32743
 Updated by:   [EMAIL PROTECTED]
 Reported By:  jj at intelequest dot com
-Status:   Bogus
+Status:   Feedback
 Bug Type: DOM XML related
 Operating System: Windows XP
 PHP Version:  5.0.4
 New Comment:

Did you load  php_domxml.dll instead if php_dom.dll?




Previous Comments:


[2005-04-18 21:27:36] jj at intelequest dot com

My bad folks 

extension=php_domxml.dll 

was still active and caused this issue.

I apologize for the wasted time. =(



[2005-04-18 21:18:30] jj at intelequest dot com

k .. 

took out zend extensions .. 

C:\temp>php -v
PHP 5.0.4 (cli) (built: Mar 31 2005 02:45:48)
Copyright (c) 1997-2004 The PHP Group
Zend Engine v2.0.4-dev, Copyright (c) 1998-2004 Zend Technologies

C:\temp>php test_xml.php

Warning: domdocument() expects parameter 2 to be long, string given in
C:\temp\test_xml.php on line 3

Fatal error: Call to undefined method domdocument::saveXML() in
C:\temp\test_xml.php on line 4


still gives an error ..



[2005-04-18 21:14:35] [EMAIL PROTECTED]

Do not file bugs when you have Zend extensions (zend_extension=)
loaded. Examples are Zend Optimizer, Zend Debugger, Turck MM Cache,
APC, Xdebug and ionCube loader.  These extensions often modify engine
behavior which is not related to PHP itself.





[2005-04-18 21:11:57] jj at intelequest dot com

Sorry .. testing with 5.0.4.

PHP 5.0.4 (cli) (built: Mar 31 2005 02:45:48)
Copyright (c) 1997-2004 The PHP Group
Zend Engine v2.0.4-dev, Copyright (c) 1998-2004 Zend Technologies
with Zend Extension Manager v1.0.7, Copyright (c) 2003-2004, by
Zend Technologies
with Zend Optimizer v2.5.8, Copyright (c) 1998-2004, by Zend
Technologies
with Zend Debugger v4.0.0, Copyright (c) 1999-2005, by Zend
Technologies



[2005-04-18 20:51:30] [EMAIL PROTECTED]

Looks like you're testing that against PHP 4.3.

I get exactly your error with PHP 4.3, but not with PHP 5...



The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/32743

-- 
Edit this bug report at http://bugs.php.net/?id=32743&edit=1


#32743 [Fbk->Opn]: Error with type of 2nd parameter when creating DOMDocument()

2005-04-18 Thread jj at intelequest dot com
 ID:   32743
 User updated by:  jj at intelequest dot com
 Reported By:  jj at intelequest dot com
-Status:   Feedback
+Status:   Open
 Bug Type: DOM XML related
 Operating System: Windows XP
 PHP Version:  5.0.4
 New Comment:

Yes, the problem was with my php.ini whereby I was loading the
php_domxml.dll in the extensions. Once I removed that from the
extensions and restarted the web service all was good with
instantiating that DOMDocument() object.


Previous Comments:


[2005-04-18 21:29:52] [EMAIL PROTECTED]

Did you load  php_domxml.dll instead if php_dom.dll?





[2005-04-18 21:27:36] jj at intelequest dot com

My bad folks 

extension=php_domxml.dll 

was still active and caused this issue.

I apologize for the wasted time. =(



[2005-04-18 21:18:30] jj at intelequest dot com

k .. 

took out zend extensions .. 

C:\temp>php -v
PHP 5.0.4 (cli) (built: Mar 31 2005 02:45:48)
Copyright (c) 1997-2004 The PHP Group
Zend Engine v2.0.4-dev, Copyright (c) 1998-2004 Zend Technologies

C:\temp>php test_xml.php

Warning: domdocument() expects parameter 2 to be long, string given in
C:\temp\test_xml.php on line 3

Fatal error: Call to undefined method domdocument::saveXML() in
C:\temp\test_xml.php on line 4


still gives an error ..



[2005-04-18 21:14:35] [EMAIL PROTECTED]

Do not file bugs when you have Zend extensions (zend_extension=)
loaded. Examples are Zend Optimizer, Zend Debugger, Turck MM Cache,
APC, Xdebug and ionCube loader.  These extensions often modify engine
behavior which is not related to PHP itself.





[2005-04-18 21:11:57] jj at intelequest dot com

Sorry .. testing with 5.0.4.

PHP 5.0.4 (cli) (built: Mar 31 2005 02:45:48)
Copyright (c) 1997-2004 The PHP Group
Zend Engine v2.0.4-dev, Copyright (c) 1998-2004 Zend Technologies
with Zend Extension Manager v1.0.7, Copyright (c) 2003-2004, by
Zend Technologies
with Zend Optimizer v2.5.8, Copyright (c) 1998-2004, by Zend
Technologies
with Zend Debugger v4.0.0, Copyright (c) 1999-2005, by Zend
Technologies



The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/32743

-- 
Edit this bug report at http://bugs.php.net/?id=32743&edit=1


#32750 [NEW]: pg_escape_string removes some backslashes

2005-04-18 Thread master-bx at users dot sourceforge dot net
From: master-bx at users dot sourceforge dot net
Operating system: Windows XP SP2
PHP version:  5.0.4
PHP Bug Type: PostgreSQL related
Bug description:  pg_escape_string removes some backslashes

Description:

Some backslashes are lost after using that function, same bug seems to be
in mysqli_real_escape_string.

Another function (mysql_real_escape_string) does well, if this is not a
bug please give me a solution to fix this.

Thank you,

hajo @ bxcp.com

Reproduce code:
---
$var = '\ \\ \\\';

$test = pg_escape_string($var);
echo $test;

Expected result:

'\ \\ \\\'

Actual result:
--
' \ \\'

-- 
Edit bug report at http://bugs.php.net/?id=32750&edit=1
-- 
Try a CVS snapshot (php4):   http://bugs.php.net/fix.php?id=32750&r=trysnapshot4
Try a CVS snapshot (php5.0): 
http://bugs.php.net/fix.php?id=32750&r=trysnapshot50
Try a CVS snapshot (php5.1): 
http://bugs.php.net/fix.php?id=32750&r=trysnapshot51
Fixed in CVS:http://bugs.php.net/fix.php?id=32750&r=fixedcvs
Fixed in release:http://bugs.php.net/fix.php?id=32750&r=alreadyfixed
Need backtrace:  http://bugs.php.net/fix.php?id=32750&r=needtrace
Need Reproduce Script:   http://bugs.php.net/fix.php?id=32750&r=needscript
Try newer version:   http://bugs.php.net/fix.php?id=32750&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=32750&r=support
Expected behavior:   http://bugs.php.net/fix.php?id=32750&r=notwrong
Not enough info: 
http://bugs.php.net/fix.php?id=32750&r=notenoughinfo
Submitted twice: 
http://bugs.php.net/fix.php?id=32750&r=submittedtwice
register_globals:http://bugs.php.net/fix.php?id=32750&r=globals
PHP 3 support discontinued:  http://bugs.php.net/fix.php?id=32750&r=php3
Daylight Savings:http://bugs.php.net/fix.php?id=32750&r=dst
IIS Stability:   http://bugs.php.net/fix.php?id=32750&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=32750&r=gnused
Floating point limitations:  http://bugs.php.net/fix.php?id=32750&r=float
No Zend Extensions:  http://bugs.php.net/fix.php?id=32750&r=nozend
MySQL Configuration Error:   http://bugs.php.net/fix.php?id=32750&r=mysqlcfg


#32751 [NEW]: Segfault after code execution (destructor calls)

2005-04-18 Thread prism at pld-linux dot org
From: prism at pld-linux dot org
Operating system: PLD Linux Distribution
PHP version:  5.0.4
PHP Bug Type: Zend Engine 2 problem
Bug description:  Segfault after code execution (destructor calls)

Description:

Zend engine or all modules which use persistent_list. 
persistent_list is destroyed after modules are unloaded. 
But some modules register own destructors for elements put 
on 
persistent_list. When Zend destroys such entry from 
persistent_list, 
it tries to call destructor from unloaded module and 
segfaults. 

Reproduce code:
---
Look here: http://comments.gmane.org/gmane.linux.pld.devel.english/785 and
start reading from post written at 16 Apr 17:33 by Michal Lukaszek, and
below from that.

Expected result:

No segfault. 

Actual result:
--
> (gdb) bt 
> #0  0xb78a6978 in ?? () 
> #1  0xb7f557da in plist_entry_destructor (ptr=0x81e11b8) 
> 
at /home/comp/rpm/BUILD/php-5.0.4/Zend/zend_list.c:204 
> #2  0xb7f5385f in zend_hash_apply_deleter (ht=0x8052c50, 
p=0x81ec1a0) 
> 
at /home/comp/rpm/BUILD/php-5.0.4/Zend/zend_hash.c:574 
> #3  0xb7f53ab0 in zend_hash_graceful_reverse_destroy 
(ht=0x8052c50) 
> 
at /home/comp/rpm/BUILD/php-5.0.4/Zend/zend_hash.c:640 
> #4  0xb7f558f6 in zend_destroy_rsrc_list (ht=0x8052c50, 
tsrm_ls=0x804f0a0) 
> 
at /home/comp/rpm/BUILD/php-5.0.4/Zend/zend_list.c:234 
> #5  0xb7f49c20 in zend_shutdown (tsrm_ls=0x804f0a0) 
> at /home/comp/rpm/BUILD/php-5.0.4/Zend/zend.c:714 
> #6  0xb7ef42d5 in php_module_shutdown 
(tsrm_ls=0x804f0a0) 
> at /home/comp/rpm/BUILD/php-5.0.4/main/main.c:1518 
> #7  0x0804be1e in main (argc=2, argv=0xb174) 
> 
at /home/comp/rpm/BUILD/php-5.0.4/sapi/cli/php_cli.c:1055 
> (gdb) f 1 
> #1  0xb7f557da in plist_entry_destructor (ptr=0x81e11b8) 
> 
at /home/comp/rpm/BUILD/php-5.0.4/Zend/zend_list.c:204 
> 204 
ld->plist_dtor_ex(le TSRMLS_CC); 
> (gdb) p ld->plist_dtor_ex 
> $1 = 0xb78a6978 
> (gdb) x ld->plist_dtor_ex 
> 0xb78a6978: Cannot access memory at address 
0xb78a6978 
 
it's in (unloaded) php-mysql module 
 
> The list here is "persistent_list", which is used by 
php-mysql for 
> persistent connection - so it's probably bug in 
php-mysql module or php 
> engine itself. 

-- 
Edit bug report at http://bugs.php.net/?id=32751&edit=1
-- 
Try a CVS snapshot (php4):   http://bugs.php.net/fix.php?id=32751&r=trysnapshot4
Try a CVS snapshot (php5.0): 
http://bugs.php.net/fix.php?id=32751&r=trysnapshot50
Try a CVS snapshot (php5.1): 
http://bugs.php.net/fix.php?id=32751&r=trysnapshot51
Fixed in CVS:http://bugs.php.net/fix.php?id=32751&r=fixedcvs
Fixed in release:http://bugs.php.net/fix.php?id=32751&r=alreadyfixed
Need backtrace:  http://bugs.php.net/fix.php?id=32751&r=needtrace
Need Reproduce Script:   http://bugs.php.net/fix.php?id=32751&r=needscript
Try newer version:   http://bugs.php.net/fix.php?id=32751&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=32751&r=support
Expected behavior:   http://bugs.php.net/fix.php?id=32751&r=notwrong
Not enough info: 
http://bugs.php.net/fix.php?id=32751&r=notenoughinfo
Submitted twice: 
http://bugs.php.net/fix.php?id=32751&r=submittedtwice
register_globals:http://bugs.php.net/fix.php?id=32751&r=globals
PHP 3 support discontinued:  http://bugs.php.net/fix.php?id=32751&r=php3
Daylight Savings:http://bugs.php.net/fix.php?id=32751&r=dst
IIS Stability:   http://bugs.php.net/fix.php?id=32751&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=32751&r=gnused
Floating point limitations:  http://bugs.php.net/fix.php?id=32751&r=float
No Zend Extensions:  http://bugs.php.net/fix.php?id=32751&r=nozend
MySQL Configuration Error:   http://bugs.php.net/fix.php?id=32751&r=mysqlcfg


#32743 [Opn->Bgs]: Error with type of 2nd parameter when creating DOMDocument()

2005-04-18 Thread amt
 ID:   32743
 Updated by:   [EMAIL PROTECTED]
 Reported By:  jj at intelequest dot com
-Status:   Open
+Status:   Bogus
 Bug Type: DOM XML related
 Operating System: Windows XP
 PHP Version:  5.0.4
 New Comment:

Not a real bug -> setting status to Bogus.


Previous Comments:


[2005-04-18 21:38:01] jj at intelequest dot com

Yes, the problem was with my php.ini whereby I was loading the
php_domxml.dll in the extensions. Once I removed that from the
extensions and restarted the web service all was good with
instantiating that DOMDocument() object.



[2005-04-18 21:29:52] [EMAIL PROTECTED]

Did you load  php_domxml.dll instead if php_dom.dll?





[2005-04-18 21:27:36] jj at intelequest dot com

My bad folks 

extension=php_domxml.dll 

was still active and caused this issue.

I apologize for the wasted time. =(



[2005-04-18 21:18:30] jj at intelequest dot com

k .. 

took out zend extensions .. 

C:\temp>php -v
PHP 5.0.4 (cli) (built: Mar 31 2005 02:45:48)
Copyright (c) 1997-2004 The PHP Group
Zend Engine v2.0.4-dev, Copyright (c) 1998-2004 Zend Technologies

C:\temp>php test_xml.php

Warning: domdocument() expects parameter 2 to be long, string given in
C:\temp\test_xml.php on line 3

Fatal error: Call to undefined method domdocument::saveXML() in
C:\temp\test_xml.php on line 4


still gives an error ..



[2005-04-18 21:14:35] [EMAIL PROTECTED]

Do not file bugs when you have Zend extensions (zend_extension=)
loaded. Examples are Zend Optimizer, Zend Debugger, Turck MM Cache,
APC, Xdebug and ionCube loader.  These extensions often modify engine
behavior which is not related to PHP itself.





The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/32743

-- 
Edit this bug report at http://bugs.php.net/?id=32743&edit=1


#30302 [Com]: Implement Document/Literal with wrapped convention

2005-04-18 Thread peter dot ordal at rochester dot edu
 ID:   30302
 Comment by:   peter dot ordal at rochester dot edu
 Reported By:  julien dot wajsberg at francetelecom dot com
 Status:   No Feedback
 Bug Type: SOAP related
 Operating System: Windows XP
 PHP Version:  5.0.2
 New Comment:

The article linked in the initial report has been taken down, but is
available via archive.org.

http://web.archive.org/web/20041012031835/http://www.burtongroup.com/weblogs/annethomasmanes/archives/2004/04/000187.html

There are some formatting issues to watch out for.

I tried dmitry's idea but I just get an emtpy stdClass object back.


Previous Comments:


[2004-12-09 01:00:03] php-bugs at lists dot php dot net

No feedback was provided for this bug for over a week, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".



[2004-12-01 18:26:25] [EMAIL PROTECTED]

ext/soap works fine with this WSDL file.

To call function on a client side use:

$client->add(array("arg1"=>2,"arg2"=>3));

On server side you can use the following function:

function add($args) {
  return $args->arg1 + $args->arg2;
}





[2004-10-01 14:45:53] julien dot wajsberg at francetelecom dot com

Description:

The mode "Document/literal with wrapped convention" is the current
industry consensus for exposing Web Services. In particular, the WS-I
explicitely forbids use of "RPC/encoded" mode, and most toolkits
vendors are working towards "document wrapped/literal".

A very good explanation of this convention can be found on
http://www.burtongroup.com/weblogs/annethomasmanes/archives/2004/04/000187.html

I would suggest adding another mode to the "style" options to
SoapClient constructor: SOAP_WRAPPED.
There should also be some logic to understand a wsdl using this
convention, but it could be done afterwards.

This convention is really very similar to "rpc/literal" mode; I didn't
test this mode, but if it's already functional, it shouldn't be hard to
implement "document wrapped/literal".







-- 
Edit this bug report at http://bugs.php.net/?id=30302&edit=1


#32752 [NEW]: Unable to load dynamic library and signal Segmentation fault

2005-04-18 Thread dcvoyager at gmail dot com
From: dcvoyager at gmail dot com
Operating system: Red Hat enterprise Linuxe ES 3
PHP version:  5.0.4
PHP Bug Type: Reproducible crash
Bug description:  Unable to load dynamic library and signal Segmentation fault

Description:

I have redhat enterprise (ES) version 3 and I had php-4.3.2-19.ent
instaled on it with httpd-2.0.46-44.ent and mysql-4.1.11.

I upgraded my php to 5.0.4 and my configure was 
./configure --prefix=/usr \
--exec-prefix=/usr \
--bindir=/usr/bin \
--sbindir=/usr/sbin \
--sysconfdir=/etc \
--datadir=/usr/share \
--includedir=/usr/include \
--libdir=/usr/lib \
--libexecdir=/usr/libexec \
--localstatedir=/var \
--sharedstatedir=/usr/com \
--mandir=/usr/share/man \
--infodir=/usr/share/info \
--cache-file=../config.cache \
--with-config-file-path=/etc \
--with-config-file-scan-dir=/etc/php.d \
--enable-force-cgi-redirect \
--disable-debug \
--enable-pic \
--disable-rpath \
--enable-inline-optimization \
--with-bz2 \
--with-db4=/usr \
--with-curl \
--with-dom=/usr \
--with-exec-dir=/usr/bin \
--with-freetype-dir=/usr \
--with-png-dir=/usr \
--with-gd \
--enable-gd-native-ttf \
--with-ttf \
--with-gettext \
--with-ncurses \
--with-gmp \
--with-iconv \
--with-jpeg-dir=/usr \
--with-openssl \
--with-png \
--with-pspell \
--with-regex=system \
--with-xml \
--with-expat-dir=/usr \
--with-pcre-regex=/usr \
--with-zlib \
--with-layout=GNU \
--enable-bcmath \
--enable-exif \
--enable-ftp \
--enable-magic-quotes \
--enable-safe-mode \
--enable-sockets \
--enable-sysvsem \
--enable-sysvshm \
--enable-discard-path \
--enable-track-vars \
--enable-trans-sid \
--enable-yp \
--enable-wddx \
--enable-mbstring \
--enable-mbstr-enc-trans \
--enable-mbregex \
--without-oci8 \
--with-pear=/usr/share/pear \
--with-imap=shared --with-imap-ssl \
--with-kerberos=/usr/kerberos \
--with-ldap=shared \
--with-mysql=shared,/usr \
--with-pgsql=shared \
--with-unixODBC=shared \
--enable-memory-limit \
--enable-bcmath \
--enable-shmop \
--enable-versioning \
--enable-calendar \
--enable-dbx \
--enable-dio \
--enable-mcal \
--with-apxs2filter=/usr/sbin/apxs

after the make and make install, I restarted apache, now none of my php
scripst works. When I looked at the error logs for httpd it gives this
error
[**error*]
[Mon Apr 18 15:08:08 2005] [notice] child pid 25188 exit signal
Segmentation fault (11) 

and also these errors

PHP Warning:  PHP Startup: : Unable to initialize module
Module compiled with module API=20020429, debug=0, thread-safety=0
PHPcompiled with module API=20041030, debug=0, thread-safety=0
These options need to match
 in Unknown on line 0
PHP Warning:  PHP Startup: Unable to load dynamic library
'/usr/lib/php4/ldap.so' - /usr/lib/php4/ldap.so: undefined symbol:
OnUpdateInt in Unknown on line 0
PHP Warning:  PHP Startup: Unable to load dynamic library
'/usr/lib/php4/mysql.so' - /usr/lib/php4/mysql.so: undefined symbol:
OnUpdateInt in Unknown on line 0
PHP Warning:  PHP Startup: Unable to load dynamic library
'/usr/lib/php4/odbc.so' - /usr/lib/php4/odbc.so: undefined symbol:
OnUpdateInt in Unknown on line 0
PHP Warning:  PHP Startup: Unable to load dynamic library
'/usr/lib/php4/pgsql.so' - /usr/lib/php4/pgsql.so: undefined symbol:
OnUpdateInt in Unknown on line 0
 

Actual result:
--
How can I make php to run normal?

-- 
Edit bug report at http://bugs.php.net/?id=32752&edit=1
-- 
Try a CVS snapshot (php4):   http://bugs.php.net/fix.php?id=32752&r=trysnapshot4
Try a CVS snapshot (php5.0): 
http://bugs.php.net/fix.php?id=32752&r=trysnapshot50
Try a CVS snapshot (php5.1): 
http://bugs.php.net/fix.php?id=32752&r=trysnapshot51
Fixed in CVS:http://bugs.php.net/fix.php?id=32752&r=fixedcvs
Fixed in release:http://bugs.php.net/fix.php?id=32752&r=alreadyfixed
Need backtrace:  http://bugs.php.net/fix.php?id=32752&r=needtrace
Need Reproduce Script:   http://bugs.php.net/fix.php?id=32752&r=needscript
Try newer version:   http://bugs.php.net/fix.php?id=32752&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=32752&r=support
Expected behavior:   http://bugs.php.net/fix.php?id=32752&r=notwrong
Not enough info: 
http://bugs.php.net/fix.php?id=32752&r=notenoughinfo
Submitted twice: 
http://bugs.php.net/fix.php?id=32752&r=submittedtwice
register_globals:http://bugs.php.net/fix.php?id=32752&r=globals
PHP 3 support discontinued:  http://bugs.php.net/fix.php?id=32752&r=php3
Daylight Savings:http://bugs.php.net/fix.php?id=32752&r=dst
IIS Stability:   http://bugs.php.net/fix.php?id=32752&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=32752&r=gnused
Floating point limitations:  http://bugs.php.net/fix.php?id=32752&r=float
No Zend Extensions:  http://bugs.php.net/fix.php?id=32752&r=nozend
MySQL Configuration Error:   http://bugs.php.net/fix.php?id=32752&r=mysqlcfg


#32753 [NEW]: Undefined Constant SQLite

2005-04-18 Thread anthony at drpimp dot com
From: anthony at drpimp dot com
Operating system: Windows XP
PHP version:  5.0.4
PHP Bug Type: *Compile Issues
Bug description:  Undefined Constant SQLite

Description:

Looks like the following constant "SQLITE_NOTADB" is missing from the
source


-- 
Edit bug report at http://bugs.php.net/?id=32753&edit=1
-- 
Try a CVS snapshot (php4):   http://bugs.php.net/fix.php?id=32753&r=trysnapshot4
Try a CVS snapshot (php5.0): 
http://bugs.php.net/fix.php?id=32753&r=trysnapshot50
Try a CVS snapshot (php5.1): 
http://bugs.php.net/fix.php?id=32753&r=trysnapshot51
Fixed in CVS:http://bugs.php.net/fix.php?id=32753&r=fixedcvs
Fixed in release:http://bugs.php.net/fix.php?id=32753&r=alreadyfixed
Need backtrace:  http://bugs.php.net/fix.php?id=32753&r=needtrace
Need Reproduce Script:   http://bugs.php.net/fix.php?id=32753&r=needscript
Try newer version:   http://bugs.php.net/fix.php?id=32753&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=32753&r=support
Expected behavior:   http://bugs.php.net/fix.php?id=32753&r=notwrong
Not enough info: 
http://bugs.php.net/fix.php?id=32753&r=notenoughinfo
Submitted twice: 
http://bugs.php.net/fix.php?id=32753&r=submittedtwice
register_globals:http://bugs.php.net/fix.php?id=32753&r=globals
PHP 3 support discontinued:  http://bugs.php.net/fix.php?id=32753&r=php3
Daylight Savings:http://bugs.php.net/fix.php?id=32753&r=dst
IIS Stability:   http://bugs.php.net/fix.php?id=32753&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=32753&r=gnused
Floating point limitations:  http://bugs.php.net/fix.php?id=32753&r=float
No Zend Extensions:  http://bugs.php.net/fix.php?id=32753&r=nozend
MySQL Configuration Error:   http://bugs.php.net/fix.php?id=32753&r=mysqlcfg


#32754 [NEW]: Segmentation fault when running xpath

2005-04-18 Thread php at max-imp dot com
From: php at max-imp dot com
Operating system: Red Hat
PHP version:  5.0.4
PHP Bug Type: DOM XML related
Bug description:  Segmentation fault when running xpath

Description:

The code below causes a segmentation fault. The line it crashes on is
$nodelist = $xpath->query( '/*' );

The machine I have the problem on is running
PHP 5.0.4
libxml 2-2.6.19

On a different machine running the following we have no issues
PHP 5.0.4-dev
libxml 2.6.16

We have installed the newest snapshot of PHP as of the April 16th, but
still had issues so we went back to PHP 5.0.4.

(There are a few notes in the code below.)

Thanks.


Reproduce code:
---
loadXml( 'http://blah.com"/>');

// ... but if i comment the line above out and uncomment the next line
there are no issues. It does not matter what xmlns is set to in the line
above.
//$x->loadXml( '' );

$xpath = new DOMXPath( $x );
$nodelist = $xpath->query( '/*' );
?>

Expected result:

Nothing should really output in this example...but we expect no
segmentation fault. :-)

Actual result:
--
Segmentation fault

This is what GDB gives me.
(gdb) run test.php
Starting program: /usr/local/bin/php test.php
[New Thread 1024 (LWP 18035)]

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 1024 (LWP 18035)]
__pthread_mutex_lock (mutex=0x1528) at mutex.c:99
99  mutex.c: No such file or directory.
in mutex.c
(gdb) bt
#0  __pthread_mutex_lock (mutex=0x1528) at mutex.c:99
#1  0x402d2974 in __libc_free (mem=0x83b22a0) at malloc.c:3152
#2  0x4020c4c6 in xmlFreePatParserContext (ctxt=0x83b22a0) at
pattern.c:293
#3  0x4020e3ef in xmlPatterncompile (pattern=0x83aa3dc "/*", dict=0x0,
flags=0, namespaces=0x83af450) at pattern.c:1899
#4  0x401b282b in xmlXPathTryStreamCompile (ctxt=0x83b0760, str=0x83aa3dc
"/*") at xpath.c:11270
#5  0x401b2afa in xmlXPathEvalExpr (ctxt=0x83af268) at xpath.c:11452
#6  0x401b2d53 in xmlXPathEvalExpression (str=0x83aa3dc "/*",
ctxt=0x83b0760) at xpath.c:11549
#7  0x0808f552 in zif_dom_xpath_query (ht=1, return_value=0x83af224,
this_ptr=0x83b228c, return_value_used=1) at
/home/krisw/php-5.0.4/ext/dom/xpath.c:198
#8  0x4040b7e1 in get_module () from
/usr/local/Zend/lib/Optimizer-2.5.7/php-5.0.x/ZendOptimizer.so
#9  0x4041985a in zend_oe () from
/usr/local/Zend/lib/Optimizer-2.5.7/php-5.0.x/ZendOptimizer.so
#10 0x081714ee in php_execute_script (primary_file=0xbfffe0e0) at
/home/krisw/php-5.0.4/main/main.c:1632
#11 0x081dd1e0 in main (argc=2, argv=0xbfffe184) at
/home/krisw/php-5.0.4/sapi/cli/php_cli.c:946
#12 0x40272306 in __libc_start_main (main=0x81dc888 , argc=2,
ubp_av=0xbfffe184, init=0x807a580 <_init>, fini=0x81f9f10 <_fini>,
rtld_fini=0x4000d2cc <_dl_fini>, stack_end=0xbfffe17c) at
../sysdeps/generic/libc-start.c:129
(gdb)


-- 
Edit bug report at http://bugs.php.net/?id=32754&edit=1
-- 
Try a CVS snapshot (php4):   http://bugs.php.net/fix.php?id=32754&r=trysnapshot4
Try a CVS snapshot (php5.0): 
http://bugs.php.net/fix.php?id=32754&r=trysnapshot50
Try a CVS snapshot (php5.1): 
http://bugs.php.net/fix.php?id=32754&r=trysnapshot51
Fixed in CVS:http://bugs.php.net/fix.php?id=32754&r=fixedcvs
Fixed in release:http://bugs.php.net/fix.php?id=32754&r=alreadyfixed
Need backtrace:  http://bugs.php.net/fix.php?id=32754&r=needtrace
Need Reproduce Script:   http://bugs.php.net/fix.php?id=32754&r=needscript
Try newer version:   http://bugs.php.net/fix.php?id=32754&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=32754&r=support
Expected behavior:   http://bugs.php.net/fix.php?id=32754&r=notwrong
Not enough info: 
http://bugs.php.net/fix.php?id=32754&r=notenoughinfo
Submitted twice: 
http://bugs.php.net/fix.php?id=32754&r=submittedtwice
register_globals:http://bugs.php.net/fix.php?id=32754&r=globals
PHP 3 support discontinued:  http://bugs.php.net/fix.php?id=32754&r=php3
Daylight Savings:http://bugs.php.net/fix.php?id=32754&r=dst
IIS Stability:   http://bugs.php.net/fix.php?id=32754&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=32754&r=gnused
Floating point limitations:  http://bugs.php.net/fix.php?id=32754&r=float
No Zend Extensions:  http://bugs.php.net/fix.php?id=32754&r=nozend
MySQL Configuration Error:   http://bugs.php.net/fix.php?id=32754&r=mysqlcfg


#32755 [NEW]: Segfault in replaceChild() when DocumentFragment has no children

2005-04-18 Thread james at safesearching dot com
From: james at safesearching dot com
Operating system: RedHat 7.3
PHP version:  5CVS-2005-04-18 (dev)
PHP Bug Type: DOM XML related
Bug description:  Segfault in replaceChild() when DocumentFragment has no 
children

Description:

Segfault occurs when calling DOMNode::replaceChild($newNode, $oldNode) if
$newNode is a DocumentFragment with no children.

The segfault occurs on line 62 of ext/dom/node.c:

dom_reconcile_ns (doc=0x81aff20, nodep=0x0)
at /home/james/php5-STABLE-200504182039/ext/dom/node.c:62
62  if (nodep->type == XML_ELEMENT_NODE) {

Code runs test against nodep->type when nodep is NULL.

Was tested on both 5.0.4 (w/ node.c,v 1.29.2.4) and 5.0.5-dev
(STABLE-200504182039).

Reproduce code:
---
\n";
$dom = new DomDocument;

$dom->loadXML($xml);

$root = $dom->documentElement;
$frag = $dom->createDocumentFragment();

$root->replaceChild($frag, $root->firstChild);

print_r($dom->saveXML());

?>


Expected result:

Not exactlly sure... perhaps issue a warning indicating that the
DocumentFragment object had no children and remove oldNode? Maybe generate
a fatal error?

Actual result:
--
Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 1024 (LWP 27878)]
dom_reconcile_ns (doc=0x81d0540, nodep=0x0)
at /home/james/php5-STABLE-200504182039/ext/dom/node.c:62
62  if (nodep->type == NULL) {


-- 
Edit bug report at http://bugs.php.net/?id=32755&edit=1
-- 
Try a CVS snapshot (php4):   http://bugs.php.net/fix.php?id=32755&r=trysnapshot4
Try a CVS snapshot (php5.0): 
http://bugs.php.net/fix.php?id=32755&r=trysnapshot50
Try a CVS snapshot (php5.1): 
http://bugs.php.net/fix.php?id=32755&r=trysnapshot51
Fixed in CVS:http://bugs.php.net/fix.php?id=32755&r=fixedcvs
Fixed in release:http://bugs.php.net/fix.php?id=32755&r=alreadyfixed
Need backtrace:  http://bugs.php.net/fix.php?id=32755&r=needtrace
Need Reproduce Script:   http://bugs.php.net/fix.php?id=32755&r=needscript
Try newer version:   http://bugs.php.net/fix.php?id=32755&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=32755&r=support
Expected behavior:   http://bugs.php.net/fix.php?id=32755&r=notwrong
Not enough info: 
http://bugs.php.net/fix.php?id=32755&r=notenoughinfo
Submitted twice: 
http://bugs.php.net/fix.php?id=32755&r=submittedtwice
register_globals:http://bugs.php.net/fix.php?id=32755&r=globals
PHP 3 support discontinued:  http://bugs.php.net/fix.php?id=32755&r=php3
Daylight Savings:http://bugs.php.net/fix.php?id=32755&r=dst
IIS Stability:   http://bugs.php.net/fix.php?id=32755&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=32755&r=gnused
Floating point limitations:  http://bugs.php.net/fix.php?id=32755&r=float
No Zend Extensions:  http://bugs.php.net/fix.php?id=32755&r=nozend
MySQL Configuration Error:   http://bugs.php.net/fix.php?id=32755&r=mysqlcfg


#32755 [Opn]: Segfault in replaceChild() when DocumentFragment has no children

2005-04-18 Thread james at safesearching dot com
 ID:   32755
 User updated by:  james at safesearching dot com
 Reported By:  james at safesearching dot com
 Status:   Open
 Bug Type: DOM XML related
 Operating System: RedHat 7.3
 PHP Version:  5CVS-2005-04-18 (dev)
 New Comment:

Reproduce code didn't quite make it all the way in... full code is:

\n";
$dom = new DomDocument;

$dom->loadXML($xml);

$root = $dom->documentElement;
$frag = $dom->createDocumentFragment();

$root->replaceChild($frag, $root->firstChild);

print_r($dom->saveXML());

?>


Previous Comments:


[2005-04-19 00:09:33] james at safesearching dot com

Description:

Segfault occurs when calling DOMNode::replaceChild($newNode, $oldNode)
if $newNode is a DocumentFragment with no children.

The segfault occurs on line 62 of ext/dom/node.c:

dom_reconcile_ns (doc=0x81aff20, nodep=0x0)
at /home/james/php5-STABLE-200504182039/ext/dom/node.c:62
62  if (nodep->type == XML_ELEMENT_NODE) {

Code runs test against nodep->type when nodep is NULL.

Was tested on both 5.0.4 (w/ node.c,v 1.29.2.4) and 5.0.5-dev
(STABLE-200504182039).

Reproduce code:
---
\n";
$dom = new DomDocument;

$dom->loadXML($xml);

$root = $dom->documentElement;
$frag = $dom->createDocumentFragment();

$root->replaceChild($frag, $root->firstChild);

print_r($dom->saveXML());

?>


Expected result:

Not exactlly sure... perhaps issue a warning indicating that the
DocumentFragment object had no children and remove oldNode? Maybe
generate a fatal error?

Actual result:
--
Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 1024 (LWP 27878)]
dom_reconcile_ns (doc=0x81d0540, nodep=0x0)
at /home/james/php5-STABLE-200504182039/ext/dom/node.c:62
62  if (nodep->type == NULL) {






-- 
Edit this bug report at http://bugs.php.net/?id=32755&edit=1


#32752 [Opn]: Unable to load dynamic library and signal Segmentation fault

2005-04-18 Thread dcvoyager at gmail dot com
 ID:   32752
 User updated by:  dcvoyager at gmail dot com
 Reported By:  dcvoyager at gmail dot com
 Status:   Open
 Bug Type: Reproducible crash
 Operating System: Red Hat enterprise Linuxe ES 3
 PHP Version:  5.0.4
 New Comment:

Now I get these errors in httpd error log after changing the extension
dir in php.ini apart and also this 

[Mon Apr 18 15:08:08 2005] [notice] child pid 25188 exit signal
Segmentation fault (11)

PHP Warning:  PHP Startup: : Unable to initialize module!Module
compiled with module API=20020429, debug=0, 

thread-safety=0!PHPcompiled with module API=20041030, debug=0,
thread-safety=0!These options need to match! in Unknown on line 0
PHP Warning:  PHP Startup: !M!!: Unable to initialize module!Module
compiled with module API=20020429, debug=0, 
thread-safety=0!PHPcompiled with module API=20041030, debug=0,
thread-safety=0!These options need to match! in Unknown on 

line 0
PHP Warning:  PHP Startup:  V!!: Unable to initialize module!Module
compiled with module API=20020429, debug=0, 

thread-safety=0!PHPcompiled with module API=20041030, debug=0,
thread-safety=0!These options need to match! in Unknown on 

line 0
PHP Warning:  PHP Startup: !]!!: Unable to initialize module!Module
compiled with module API=20020429, debug=0, 

thread-safety=0!PHPcompiled with module API=20041030, debug=0,
thread-safety=0!These options need to match! in Unknown on 

line 0
PHP Warning:  PHP Startup: : Unable to initialize module!Module
compiled with module API=20020429, debug=0, 

thread-safety=0!PHPcompiled with module API=20041030, debug=0,
thread-safety=0!These options need to match! in Unknown on 

line 0


Previous Comments:


[2005-04-18 22:34:01] dcvoyager at gmail dot com

Description:

I have redhat enterprise (ES) version 3 and I had php-4.3.2-19.ent
instaled on it with httpd-2.0.46-44.ent and mysql-4.1.11.

I upgraded my php to 5.0.4 and my configure was 
./configure --prefix=/usr \
--exec-prefix=/usr \
--bindir=/usr/bin \
--sbindir=/usr/sbin \
--sysconfdir=/etc \
--datadir=/usr/share \
--includedir=/usr/include \
--libdir=/usr/lib \
--libexecdir=/usr/libexec \
--localstatedir=/var \
--sharedstatedir=/usr/com \
--mandir=/usr/share/man \
--infodir=/usr/share/info \
--cache-file=../config.cache \
--with-config-file-path=/etc \
--with-config-file-scan-dir=/etc/php.d \
--enable-force-cgi-redirect \
--disable-debug \
--enable-pic \
--disable-rpath \
--enable-inline-optimization \
--with-bz2 \
--with-db4=/usr \
--with-curl \
--with-dom=/usr \
--with-exec-dir=/usr/bin \
--with-freetype-dir=/usr \
--with-png-dir=/usr \
--with-gd \
--enable-gd-native-ttf \
--with-ttf \
--with-gettext \
--with-ncurses \
--with-gmp \
--with-iconv \
--with-jpeg-dir=/usr \
--with-openssl \
--with-png \
--with-pspell \
--with-regex=system \
--with-xml \
--with-expat-dir=/usr \
--with-pcre-regex=/usr \
--with-zlib \
--with-layout=GNU \
--enable-bcmath \
--enable-exif \
--enable-ftp \
--enable-magic-quotes \
--enable-safe-mode \
--enable-sockets \
--enable-sysvsem \
--enable-sysvshm \
--enable-discard-path \
--enable-track-vars \
--enable-trans-sid \
--enable-yp \
--enable-wddx \
--enable-mbstring \
--enable-mbstr-enc-trans \
--enable-mbregex \
--without-oci8 \
--with-pear=/usr/share/pear \
--with-imap=shared --with-imap-ssl \
--with-kerberos=/usr/kerberos \
--with-ldap=shared \
--with-mysql=shared,/usr \
--with-pgsql=shared \
--with-unixODBC=shared \
--enable-memory-limit \
--enable-bcmath \
--enable-shmop \
--enable-versioning \
--enable-calendar \
--enable-dbx \
--enable-dio \
--enable-mcal \
--with-apxs2filter=/usr/sbin/apxs

after the make and make install, I restarted apache, now none of my php
scripst works. When I looked at the error logs for httpd it gives this
error
[**error*]
[Mon Apr 18 15:08:08 2005] [notice] child pid 25188 exit signal
Segmentation fault (11) 

and also these errors

PHP Warning:  PHP Startup: : Unable to initialize module
Module compiled with module API=20020429, debug=0, thread-safety=0
PHPcompiled with module API=20041030, debug=0, thread-safety=0
These options need to match
 in Unknown on line 0
PHP Warning:  PHP Startup: Unable to load dynamic library
'/usr/lib/php4/ldap.so' - /usr/lib/php4/ldap.so: undefined symbol:
OnUpdateInt in Unknown on line 0
PHP Warning:  PHP Startup: Unable to load dynamic library
'/usr/lib/php4/mysql.so' - /usr/lib/php4/mysql.so: undefined symbol:
OnUpdateInt in Unknown on line 0
PHP Warning:  PHP Startup: Unable to load dynamic library
'/usr/lib/php4/odbc.so' - /usr/lib/php4/odbc.so: undefined symbol:
OnUpdateInt in Unknown on line 0
PHP Warning:  PHP Startup: Unable to load dynamic library
'/usr/lib/php4/pgsql.so' - /usr/lib/php4/pgsql.so: undefined symbol:
OnUpdateInt in Unknown on line 0
 

Actual result:
--
How can I make php to run normal?


---

#32756 [NEW]: hacker

2005-04-18 Thread jjkjwo at yahoo dot com
From: jjkjwo at yahoo dot com
Operating system: winxp
PHP version:  4.3.11
PHP Bug Type: Unknown/Other Function
Bug description:  hacker

Description:

www.g00ns.com
Has been hacking various forums, THIS IS A LEGAL ISSUE.
I suggest this company hire a firm and investigate this IMIDIATLY


-- 
Edit bug report at http://bugs.php.net/?id=32756&edit=1
-- 
Try a CVS snapshot (php4):   http://bugs.php.net/fix.php?id=32756&r=trysnapshot4
Try a CVS snapshot (php5.0): 
http://bugs.php.net/fix.php?id=32756&r=trysnapshot50
Try a CVS snapshot (php5.1): 
http://bugs.php.net/fix.php?id=32756&r=trysnapshot51
Fixed in CVS:http://bugs.php.net/fix.php?id=32756&r=fixedcvs
Fixed in release:http://bugs.php.net/fix.php?id=32756&r=alreadyfixed
Need backtrace:  http://bugs.php.net/fix.php?id=32756&r=needtrace
Need Reproduce Script:   http://bugs.php.net/fix.php?id=32756&r=needscript
Try newer version:   http://bugs.php.net/fix.php?id=32756&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=32756&r=support
Expected behavior:   http://bugs.php.net/fix.php?id=32756&r=notwrong
Not enough info: 
http://bugs.php.net/fix.php?id=32756&r=notenoughinfo
Submitted twice: 
http://bugs.php.net/fix.php?id=32756&r=submittedtwice
register_globals:http://bugs.php.net/fix.php?id=32756&r=globals
PHP 3 support discontinued:  http://bugs.php.net/fix.php?id=32756&r=php3
Daylight Savings:http://bugs.php.net/fix.php?id=32756&r=dst
IIS Stability:   http://bugs.php.net/fix.php?id=32756&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=32756&r=gnused
Floating point limitations:  http://bugs.php.net/fix.php?id=32756&r=float
No Zend Extensions:  http://bugs.php.net/fix.php?id=32756&r=nozend
MySQL Configuration Error:   http://bugs.php.net/fix.php?id=32756&r=mysqlcfg


#32596 [Opn]: Segfault/Memory Leak by getClass (etc) in __destruct

2005-04-18 Thread mailfrom-bugs dot php dot net at kopka dot net
 ID:   32596
 User updated by:  mailfrom-bugs dot php dot net at kopka dot net
 Reported By:  mailfrom-bugs dot php dot net at kopka dot net
 Status:   Open
 Bug Type: Reproducible crash
 Operating System: Linux (Gentoo)
 PHP Version:  5CVS-2005-04-05 (dev)
 New Comment:

PHP-5.1.0-dev (build Apr 10 2005) is free of this problem.


Previous Comments:


[2005-04-05 20:09:19] mailfrom-bugs dot php dot net at kopka dot net

Description:

getClass($this) and others segfault or leak memory (when
--enable-debug) on 
PHP 5.0.3
PHP 5.0.4
PHP 5.0.5-dev (cli) (2005-04-05 11:42:27)
build on gentoo linux (default install flags).

I ran into this using the following construct:

if (database::query($string)->error) {}

where database::query() returns an object wrapping a result set (or
providing info on success of the request).

PHP 5.0.3 (and i am quite sure this applies to other versions as well
as i experience this for quite a time) segfaults under the following
cumulating circumstances:
- If the object is only used once and not referenced to a variable
- If a property is read/set (if a function is called all is OK)
- If __destruct references the class name by some means (others are
OK)

When you try the demo uncomment one of the lines which cause a segfault
(and are noted as a memory leak with --enable-debug):

//  $c=get_class($this);unset ($c);
//  echo get_class($this);
//  if(defined('DEBUG_'.__CLASS__)){}

The following lines don't raise a segfault:

  $c=__CLASS__;unset($c);
  if(__CLASS__ == "BUG") {};
  get_class($this);
  echo __CLASS__;

The following line don't raise a segfault but is noted as a memory leak
(--enable-debug):

  $c=get_class($this);

Naturally the hidden beast came up a long time after i wrote the line -
spending a good month of free time trying to locate it i am happy to
finally nail it to the ground for someone who knows what he is doing to
slay it (it cost me a keyboard and brought quite a few white hairs into
existence).

Since the original bug report vanished from the bug list (and can only
be found by number for reasons that escape me) i opened  it again (and
closed the other).

Good hunting.

Configure Command =>  './configure' '--prefix=/usr'
'--host=i686-pc-linux-gnu' '--mandir=/usr/share/man'
'--infodir=/usr/share/info' '--datadir=/usr/share' '--sysconfdir=/etc'
'--localstatedir=/var/lib' '--disable-cgi' '--enable-cli'
'--enable-embed' '--with-config-file-path=/etc/php/cli-php5'
'--disable-bcmath' '--without-bz2' '--disable-calendar'
'--without-cpdflib' '--disable-ctype' '--without-curl'
'--without-curlwrappers' '--disable-dbase' '--disable-dio'
'--disable-dom' '--disable-exif' '--without-fam' '--without-fbsql'
'--without-fdftk' '--disable-filepro' '--disable-ftp'
'--without-gettext' '--without-gmp' '--without-hwapi' '--without-iconv'
'--without-informix' '--without-ingres' '--without-interbase'
'--without-kerberos' '--disable-libxml' '--disable-mbstring'
'--without-mcrypt' '--without-mcve' '--disable-memory-limit'
'--without-mhash' '--without-mime-magic' '--without-ming'
'--without-mnogosearch' '--without-msql' '--without-mssql'
'--without-ncurses' '--without-oci8' '--without-oracle'
'--without-openssl' '--without-openssl-dir' '--without-ovrimos'
'--disable-pcntl' '--without-pcre-regx' '--without-pfpro'
'--without-pgsql' '--disable-posix' '--without-pspell'
'--without-recode' '--disable-simplexml' '--disable-shmop'
'--without-snmp' '--disable-soap' '--disable-sockets' '--disable-spl'
'--without-sybase' '--without-sybase-ct' '--disable-sysvmsg'
'--disable-sysvsem' '--disable-sysvshm' '--without-tidy'
'--disable-tokenizer' '--disable-wddx' '--without-xsl'
'--without-xmlrpc' '--disable-yp' '--without-zlib' '--disable-debug'
'--without-jpeg-dir' '--without-freetype-dir' '--without-t1lib'
'--without-ttf' '--disable-gd-jis-conf' '--disable-gd-native-ttf'
'--without-png-dir' '--without-tiff-dir' '--without-xpm-dir'
'--without-gd' '--disable-session' '--without-sqlite' '--disable-dba'
'--without-readline' '--without-libedit'


Reproduce code:
---
error;
  }
}

BUG::instance()->error;
echo "this is still executed\n";

?>

Expected result:

Expected result:

# php -n bug.php(cr)
please fix this thing, it wasted a nice part of my life!
this is still executed
# (cursor)

Actual result:
--
Sorry that i can not provide a core dump according to the requested
standards (vith --enable-debug) because if i compile like this there
is
no segfault (just a memory leak), so i hope a standard one will help:
--
(with --disable-debug)
# php -n bug.php (cr)
please fix this thing, it wasted a nice part of my life!
this is still executed
Segmentation fault (core dumped)
# gdb php core
GNU gdb 6.0
Copyright 2003 Free Software Foundation, Inc.
GDB is free software, covered by th

#32738 [Bgs]: large array keys causes memory corruption and segfaults

2005-04-18 Thread pvandijk at gmail dot com
 ID:   32738
 User updated by:  pvandijk at gmail dot com
 Reported By:  pvandijk at gmail dot com
 Status:   Bogus
 Bug Type: Reproducible crash
 Operating System: Linux 2.4.22-1.2115.nptl
 PHP Version:  4.3.11
 New Comment:

Perhaps the reason i was unable to find the previous error reports is
that they seem to date back to 2002.

If this is indeed the same issue as Bug #16149 then i'm a little
puzzled as to why it hasnt been fixed over the past 3 years. maybe the
issue is more complex than just changing the ushort refcount, to a uint
in the _zval_struct?


Previous Comments:


[2005-04-18 08:42:31] [EMAIL PROTECTED]

Please do not submit the same bug more than once. An existing
bug report already describes this very problem. Even if you feel
that your issue is somewhat different, the resolution is likely
to be the same. 

Thank you for your interest in PHP.

This is because we have a 2 byte refcount counter. You're adding too
many (internal) references to $data overflowing the counter. When it
hits zero the data is free and you can't access it anymore - resulting
in the segfault.



[2005-04-18 02:50:16] pvandijk at gmail dot com

Description:

Hashes with a large number of keys and large key data size seem to
cause memory corruption, which in turn causes php to either segfault or
hang upon exiting (depending on the context of the code).

I've heard mention that arrays are not unlimited in size. This issue
seems to occur at about 65535 elements in my tests, but also depends on
the size of the keys. Presumably this is because i'm indexing my arrays
with Strings, and therefore it's running out of memory faster.

If the memory limit of a hash is reached, should it not be handled more
gracefully than corrupting memory, which results in a segfault?

The code example i've provided seems to reproduce a crash under both
linux and windows, php 4.3.11

Reproduce code:
---
 $value) {
if($data != $value) {
print 'invalid value: '. $k .' => '. $value ."\r\n";
}
}
}
check($ar);
print 'done.'."\r\n";
?>

Expected result:

done.

Actual result:
--
"done.
Segmentation fault"

sorry i cant provide a backtrace or any further info, i dont have
access to these tools on my current dev server.






-- 
Edit this bug report at http://bugs.php.net/?id=32738&edit=1


#32755 [Opn->Csd]: Segfault in replaceChild() when DocumentFragment has no children

2005-04-18 Thread rrichards
 ID:   32755
 Updated by:   [EMAIL PROTECTED]
 Reported By:  james at safesearching dot com
-Status:   Open
+Status:   Closed
 Bug Type: DOM XML related
 Operating System: RedHat 7.3
 PHP Version:  5CVS-2005-04-18 (dev)
 New Comment:

This bug has been fixed in CVS.

Snapshots of the sources are packaged every three hours; this change
will be in the next snapshot. You can grab the snapshot at
http://snaps.php.net/.
 
Thank you for the report, and for helping us make PHP better.




Previous Comments:


[2005-04-19 00:12:08] james at safesearching dot com

Reproduce code didn't quite make it all the way in... full code is:

\n";
$dom = new DomDocument;

$dom->loadXML($xml);

$root = $dom->documentElement;
$frag = $dom->createDocumentFragment();

$root->replaceChild($frag, $root->firstChild);

print_r($dom->saveXML());

?>



[2005-04-19 00:09:33] james at safesearching dot com

Description:

Segfault occurs when calling DOMNode::replaceChild($newNode, $oldNode)
if $newNode is a DocumentFragment with no children.

The segfault occurs on line 62 of ext/dom/node.c:

dom_reconcile_ns (doc=0x81aff20, nodep=0x0)
at /home/james/php5-STABLE-200504182039/ext/dom/node.c:62
62  if (nodep->type == XML_ELEMENT_NODE) {

Code runs test against nodep->type when nodep is NULL.

Was tested on both 5.0.4 (w/ node.c,v 1.29.2.4) and 5.0.5-dev
(STABLE-200504182039).

Reproduce code:
---
\n";
$dom = new DomDocument;

$dom->loadXML($xml);

$root = $dom->documentElement;
$frag = $dom->createDocumentFragment();

$root->replaceChild($frag, $root->firstChild);

print_r($dom->saveXML());

?>


Expected result:

Not exactlly sure... perhaps issue a warning indicating that the
DocumentFragment object had no children and remove oldNode? Maybe
generate a fatal error?

Actual result:
--
Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 1024 (LWP 27878)]
dom_reconcile_ns (doc=0x81d0540, nodep=0x0)
at /home/james/php5-STABLE-200504182039/ext/dom/node.c:62
62  if (nodep->type == NULL) {






-- 
Edit this bug report at http://bugs.php.net/?id=32755&edit=1


#32663 [Fbk->NoF]: odbc_fetch_row fails to get single selected MySQL text column

2005-04-18 Thread php-bugs
 ID:   32663
 Updated by:   php-bugs@lists.php.net
 Reported By:  mizmerize at yahoo dot com
-Status:   Feedback
+Status:   No Feedback
 Bug Type: ODBC related
 Operating System: Windows 2000 Advanced Server SP3
 PHP Version:  5.0.4
 New Comment:

No feedback was provided for this bug for over a week, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".


Previous Comments:


[2005-04-11 17:57:36] [EMAIL PROTECTED]

Thank you for this bug report. To properly diagnose the problem, we
need a short but complete example script to be able to reproduce
this bug ourselves. 

A proper reproducing script starts with ,
is max. 10-20 lines long and does not require any external 
resources such as databases, etc.

If possible, make the script source available online and provide
an URL to it here. Try to avoid embedding huge scripts into the report.





[2005-04-11 03:27:52] mizmerize at yahoo dot com

Description:

I used ODBC Unified using a MyODBC driver version 3.51.11 and connected
to a table with a varchar and a TEXT  column. Then I created a query
like this:

$sql="SELECT Title FROM tbllibrarymaterials"

.. the odbc_exec function does good. It provides a non-false result.
but if I have to get the rows by using odbc_fetch_row,  this function
returns false and I could not get a record.

But...

If I defined another column along with the query:

$sql="SELECT Title, Call_Number FROM tbllibrarymaterials"

...I get the expected results.

[PHP.INI]
odbc.longreadlen=65535 
odbc.binmode=1

I set this because it may be the problem with long columns. But this
settings did not change anything.

Reproduce code:
---
To reproduce the bug, you must create a table called "tbllibmaterials"
(or any name) in MySQL with a varchar(50) for the Call_Number and TEXT
column for the Title, and use odbc_fetch_row running the query:

$sql="SELECT Title FROM tbllibrarymaterials"

Expected result:

No records can be retrieved.

Actual result:
--
No records can be retrieved.





-- 
Edit this bug report at http://bugs.php.net/?id=32663&edit=1


#32678 [Fbk->NoF]: An extra Line Feed ( 0x0A) is added when downloading Files

2005-04-18 Thread php-bugs
 ID:   32678
 Updated by:   php-bugs@lists.php.net
 Reported By:  kosuri dot s dot raju at chase dot com
-Status:   Feedback
+Status:   No Feedback
 Bug Type: iPlanet related
 Operating System: Win 2000 (build 2195), SP4
 PHP Version:  4.3.10
 New Comment:

No feedback was provided for this bug for over a week, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".


Previous Comments:


[2005-04-12 00:02:17] [EMAIL PROTECTED]

Please try using this CVS snapshot:

  http://snaps.php.net/php5-latest.tar.gz
 
For Windows:
 
  http://snaps.php.net/win32/php5-win32-latest.zip





[2005-04-11 21:46:37] kosuri dot s dot raju at chase dot com

Description:

Environment:
 Windows 2000, V5.0.2195 SP 4
 Sun one Webserver 6.1  SP2
 PHP 4.3.10 (cgi-fcgi) (built: Dec 14 2004 17:47:59)

 Using NSAPI
 MySQL
 Browser: IE6.0
 
When dowloading a file ( both text and Binary files ), an extra LF
Character (0x0A) is always prepende to the output.  This is only
happening in the above environment.   The data is stored properly on
the MySql Server.  Works OK on Windows XP , SP2 ( environment)  


Reproduce code:
---
Sample Code:

$inData = // Read Data from mySQL
$ctype = "text/plain" ; // or like appilcation/msword
header("Pragma: public");
header("Expires: 0");
header("Cache-Control: must-revalidate, post-check=0, pre-check=0");
header("Cache-Control: public");
header("Content-type: $ctype");
header( "Content-Disposition: attachment; filename=".$filenam );
header("Content-Transfer-Encoding: binary");
header("Content-Length: ".$filesize);
echo($inData);
exit;


Expected result:

The output should not contain additional LineFeed character at the
start of output

Actual result:
--
  --- This is Extra Linefeed ( 0x0A)
B





-- 
Edit this bug report at http://bugs.php.net/?id=32678&edit=1


#32754 [Opn]: Segmentation fault when running xpath

2005-04-18 Thread php at max-imp dot com
 ID:   32754
 User updated by:  php at max-imp dot com
 Reported By:  php at max-imp dot com
 Status:   Open
 Bug Type: DOM XML related
 Operating System: Red Hat
 PHP Version:  5.0.4
 New Comment:

Installing libxml 2.6.16 seems to have solved the issue. There seems to
be some incompatibility issue between PHP 5.0.4 and libxml 2.6.19


Previous Comments:


[2005-04-18 22:50:08] php at max-imp dot com

Description:

The code below causes a segmentation fault. The line it crashes on is
$nodelist = $xpath->query( '/*' );

The machine I have the problem on is running
PHP 5.0.4
libxml 2-2.6.19

On a different machine running the following we have no issues
PHP 5.0.4-dev
libxml 2.6.16

We have installed the newest snapshot of PHP as of the April 16th, but
still had issues so we went back to PHP 5.0.4.

(There are a few notes in the code below.)

Thanks.


Reproduce code:
---
loadXml( 'http://blah.com"/>');

// ... but if i comment the line above out and uncomment the next line
there are no issues. It does not matter what xmlns is set to in the
line above.
//$x->loadXml( '' );

$xpath = new DOMXPath( $x );
$nodelist = $xpath->query( '/*' );
?>

Expected result:

Nothing should really output in this example...but we expect no
segmentation fault. :-)

Actual result:
--
Segmentation fault

This is what GDB gives me.
(gdb) run test.php
Starting program: /usr/local/bin/php test.php
[New Thread 1024 (LWP 18035)]

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 1024 (LWP 18035)]
__pthread_mutex_lock (mutex=0x1528) at mutex.c:99
99  mutex.c: No such file or directory.
in mutex.c
(gdb) bt
#0  __pthread_mutex_lock (mutex=0x1528) at mutex.c:99
#1  0x402d2974 in __libc_free (mem=0x83b22a0) at malloc.c:3152
#2  0x4020c4c6 in xmlFreePatParserContext (ctxt=0x83b22a0) at
pattern.c:293
#3  0x4020e3ef in xmlPatterncompile (pattern=0x83aa3dc "/*", dict=0x0,
flags=0, namespaces=0x83af450) at pattern.c:1899
#4  0x401b282b in xmlXPathTryStreamCompile (ctxt=0x83b0760,
str=0x83aa3dc "/*") at xpath.c:11270
#5  0x401b2afa in xmlXPathEvalExpr (ctxt=0x83af268) at xpath.c:11452
#6  0x401b2d53 in xmlXPathEvalExpression (str=0x83aa3dc "/*",
ctxt=0x83b0760) at xpath.c:11549
#7  0x0808f552 in zif_dom_xpath_query (ht=1, return_value=0x83af224,
this_ptr=0x83b228c, return_value_used=1) at
/home/krisw/php-5.0.4/ext/dom/xpath.c:198
#8  0x4040b7e1 in get_module () from
/usr/local/Zend/lib/Optimizer-2.5.7/php-5.0.x/ZendOptimizer.so
#9  0x4041985a in zend_oe () from
/usr/local/Zend/lib/Optimizer-2.5.7/php-5.0.x/ZendOptimizer.so
#10 0x081714ee in php_execute_script (primary_file=0xbfffe0e0) at
/home/krisw/php-5.0.4/main/main.c:1632
#11 0x081dd1e0 in main (argc=2, argv=0xbfffe184) at
/home/krisw/php-5.0.4/sapi/cli/php_cli.c:946
#12 0x40272306 in __libc_start_main (main=0x81dc888 , argc=2,
ubp_av=0xbfffe184, init=0x807a580 <_init>, fini=0x81f9f10 <_fini>,
rtld_fini=0x4000d2cc <_dl_fini>, stack_end=0xbfffe17c) at
../sysdeps/generic/libc-start.c:129
(gdb)






-- 
Edit this bug report at http://bugs.php.net/?id=32754&edit=1


#32754 [Opn->Bgs]: Segmentation fault when running xpath

2005-04-18 Thread rrichards
 ID:   32754
 Updated by:   [EMAIL PROTECTED]
 Reported By:  php at max-imp dot com
-Status:   Open
+Status:   Bogus
 Bug Type: DOM XML related
 Operating System: Red Hat
 PHP Version:  5.0.4
 New Comment:

Do not file bugs when you have Zend extensions (zend_extension=)
loaded. Examples are Zend Optimizer, Zend Debugger, Turck MM Cache,
APC, Xdebug and ionCube loader.  These extensions often modify engine
behavior which is not related to PHP itself.




Previous Comments:


[2005-04-19 02:04:47] php at max-imp dot com

Installing libxml 2.6.16 seems to have solved the issue. There seems to
be some incompatibility issue between PHP 5.0.4 and libxml 2.6.19



[2005-04-18 22:50:08] php at max-imp dot com

Description:

The code below causes a segmentation fault. The line it crashes on is
$nodelist = $xpath->query( '/*' );

The machine I have the problem on is running
PHP 5.0.4
libxml 2-2.6.19

On a different machine running the following we have no issues
PHP 5.0.4-dev
libxml 2.6.16

We have installed the newest snapshot of PHP as of the April 16th, but
still had issues so we went back to PHP 5.0.4.

(There are a few notes in the code below.)

Thanks.


Reproduce code:
---
loadXml( 'http://blah.com"/>');

// ... but if i comment the line above out and uncomment the next line
there are no issues. It does not matter what xmlns is set to in the
line above.
//$x->loadXml( '' );

$xpath = new DOMXPath( $x );
$nodelist = $xpath->query( '/*' );
?>

Expected result:

Nothing should really output in this example...but we expect no
segmentation fault. :-)

Actual result:
--
Segmentation fault

This is what GDB gives me.
(gdb) run test.php
Starting program: /usr/local/bin/php test.php
[New Thread 1024 (LWP 18035)]

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 1024 (LWP 18035)]
__pthread_mutex_lock (mutex=0x1528) at mutex.c:99
99  mutex.c: No such file or directory.
in mutex.c
(gdb) bt
#0  __pthread_mutex_lock (mutex=0x1528) at mutex.c:99
#1  0x402d2974 in __libc_free (mem=0x83b22a0) at malloc.c:3152
#2  0x4020c4c6 in xmlFreePatParserContext (ctxt=0x83b22a0) at
pattern.c:293
#3  0x4020e3ef in xmlPatterncompile (pattern=0x83aa3dc "/*", dict=0x0,
flags=0, namespaces=0x83af450) at pattern.c:1899
#4  0x401b282b in xmlXPathTryStreamCompile (ctxt=0x83b0760,
str=0x83aa3dc "/*") at xpath.c:11270
#5  0x401b2afa in xmlXPathEvalExpr (ctxt=0x83af268) at xpath.c:11452
#6  0x401b2d53 in xmlXPathEvalExpression (str=0x83aa3dc "/*",
ctxt=0x83b0760) at xpath.c:11549
#7  0x0808f552 in zif_dom_xpath_query (ht=1, return_value=0x83af224,
this_ptr=0x83b228c, return_value_used=1) at
/home/krisw/php-5.0.4/ext/dom/xpath.c:198
#8  0x4040b7e1 in get_module () from
/usr/local/Zend/lib/Optimizer-2.5.7/php-5.0.x/ZendOptimizer.so
#9  0x4041985a in zend_oe () from
/usr/local/Zend/lib/Optimizer-2.5.7/php-5.0.x/ZendOptimizer.so
#10 0x081714ee in php_execute_script (primary_file=0xbfffe0e0) at
/home/krisw/php-5.0.4/main/main.c:1632
#11 0x081dd1e0 in main (argc=2, argv=0xbfffe184) at
/home/krisw/php-5.0.4/sapi/cli/php_cli.c:946
#12 0x40272306 in __libc_start_main (main=0x81dc888 , argc=2,
ubp_av=0xbfffe184, init=0x807a580 <_init>, fini=0x81f9f10 <_fini>,
rtld_fini=0x4000d2cc <_dl_fini>, stack_end=0xbfffe17c) at
../sysdeps/generic/libc-start.c:129
(gdb)






-- 
Edit this bug report at http://bugs.php.net/?id=32754&edit=1


#32727 [Fbk->Opn]: Slow serialize on FreeBSD

2005-04-18 Thread cws at miraclenet dot co dot th
 ID:   32727
 User updated by:  cws at miraclenet dot co dot th
 Reported By:  cws at miraclenet dot co dot th
-Status:   Feedback
+Status:   Open
 Bug Type: Performance problem
 Operating System: FreeBSD
 PHP Version:  4.3.11
 New Comment:

No it don't help me to speed up my test code.
This is the result

[EMAIL PROTECTED] ./php test.php
Content-type: text/html
X-Powered-By: PHP/5.1.0-dev

version:5.1.0-dev
Length: 2798041
Serialize time:  elapse(2.136879)

[EMAIL PROTECTED] /usr/local/bin/php test.php
version:4.3.11
Length: 2798041
Serialize time:  elapse(0.200818)

The test code and data can be download at
http://freebie.miraclenet.co.th/tmp/test_serialize.tgz

The test data may seem too extreme (an array of 2.8M) but it is the one
that our customer really use.


Previous Comments:


[2005-04-16 16:38:42] [EMAIL PROTECTED]

Please try using this CVS snapshot:

  http://snaps.php.net/php5-latest.tar.gz
 
For Windows:
 
  http://snaps.php.net/win32/php5-win32-latest.zip

PHP 5.1-dev has got some optimizing done in this part, see if it's any
better (without your patch of course)




[2005-04-16 13:39:18] cws at miraclenet dot co dot th

This is a patch 

t42# diff -u ext/standard/php_smart_str.h /home/cws/php_smart_str.h
--- ext/standard/php_smart_str.hWed Apr 16 16:12:37 2003
+++ /home/cws/php_smart_str.h   Sat Apr 16 18:27:30 2005
@@ -32,6 +32,10 @@
 #define SMART_STR_PREALLOC 128
 #endif

+#ifndef SMART_PTR_MAX_PREALLOC
+#define SMART_PTR_MAX_PREALLOC 1048576
+#endif
+
 #ifdef SMART_STR_USE_REALLOC
 #define SMART_STR_REALLOC(a,b,c) realloc((a),(b))
 #else
@@ -42,8 +46,11 @@
if (!d->c) d->len = d->a = 0; \
newlen = d->len + n; \
if (newlen >= d->a) {\
-   d->c = SMART_STR_REALLOC(d->c, newlen +
SMART_STR_PREALLOC + 1, what); \
-   d->a = newlen + SMART_STR_PREALLOC; \
+   size_t pre_alloc = newlen *2;\
+   if ( pre_alloc > SMART_PTR_MAX_PREALLOC ) { pre_alloc =
SMART_PTR_MAX_PREALLOC; }\
+   if ( pre_alloc < SMART_STR_PREALLOC) { pre_alloc =
SMART_STR_PREALLOC; }\
+   d->c = SMART_STR_REALLOC(d->c, newlen + pre_alloc + 1,
what); \
+   d->a = newlen + pre_alloc; \
}\
 }



[2005-04-16 13:08:32] cws at miraclenet dot co dot th

Description:

serialize use a lot of realloc which are very slow on FreeBSD

>From - http://rgarciasuarez.free.fr/p5p/p5p-200307-1.pod -

Dan Kogai explained that FreeBSD comes with an implementation of
malloc()
that is optimized for paged memory, and safe from duplicate free()
calls.
But the downside is that realloc() is very slow. That's usually not a
big
deal, because most programs don't use realloc() very often -- but perl
does. (The default configuration of perl on FreeBSD is to use perl's
internal malloc, that hasn't this realloc limitation.)

Serialize use a fix incremental value (SMART_STR_PREALLOC in
php_smart_ptr.h). It better for serialize to use exponential
incremential value to reduce number of realloc. 






-- 
Edit this bug report at http://bugs.php.net/?id=32727&edit=1


#32727 [Opn]: Slow serialize on FreeBSD

2005-04-18 Thread cws at miraclenet dot co dot th
 ID:   32727
 User updated by:  cws at miraclenet dot co dot th
 Reported By:  cws at miraclenet dot co dot th
 Status:   Open
 Bug Type: Performance problem
 Operating System: FreeBSD
 PHP Version:  4.3.11
 New Comment:

I forget to mension that the previous result is 
from my patched version.
The result of unpatch one is

[EMAIL PROTECTED] ./php test_serialize.php
version:4.3.11
Length: 2798041
Serialize time:  elapse(2.554760)


Previous Comments:


[2005-04-19 02:36:12] cws at miraclenet dot co dot th

No it don't help me to speed up my test code.
This is the result

[EMAIL PROTECTED] ./php test.php
Content-type: text/html
X-Powered-By: PHP/5.1.0-dev

version:5.1.0-dev
Length: 2798041
Serialize time:  elapse(2.136879)

[EMAIL PROTECTED] /usr/local/bin/php test.php
version:4.3.11
Length: 2798041
Serialize time:  elapse(0.200818)

The test code and data can be download at
http://freebie.miraclenet.co.th/tmp/test_serialize.tgz

The test data may seem too extreme (an array of 2.8M) but it is the one
that our customer really use.



[2005-04-16 16:38:42] [EMAIL PROTECTED]

Please try using this CVS snapshot:

  http://snaps.php.net/php5-latest.tar.gz
 
For Windows:
 
  http://snaps.php.net/win32/php5-win32-latest.zip

PHP 5.1-dev has got some optimizing done in this part, see if it's any
better (without your patch of course)




[2005-04-16 13:39:18] cws at miraclenet dot co dot th

This is a patch 

t42# diff -u ext/standard/php_smart_str.h /home/cws/php_smart_str.h
--- ext/standard/php_smart_str.hWed Apr 16 16:12:37 2003
+++ /home/cws/php_smart_str.h   Sat Apr 16 18:27:30 2005
@@ -32,6 +32,10 @@
 #define SMART_STR_PREALLOC 128
 #endif

+#ifndef SMART_PTR_MAX_PREALLOC
+#define SMART_PTR_MAX_PREALLOC 1048576
+#endif
+
 #ifdef SMART_STR_USE_REALLOC
 #define SMART_STR_REALLOC(a,b,c) realloc((a),(b))
 #else
@@ -42,8 +46,11 @@
if (!d->c) d->len = d->a = 0; \
newlen = d->len + n; \
if (newlen >= d->a) {\
-   d->c = SMART_STR_REALLOC(d->c, newlen +
SMART_STR_PREALLOC + 1, what); \
-   d->a = newlen + SMART_STR_PREALLOC; \
+   size_t pre_alloc = newlen *2;\
+   if ( pre_alloc > SMART_PTR_MAX_PREALLOC ) { pre_alloc =
SMART_PTR_MAX_PREALLOC; }\
+   if ( pre_alloc < SMART_STR_PREALLOC) { pre_alloc =
SMART_STR_PREALLOC; }\
+   d->c = SMART_STR_REALLOC(d->c, newlen + pre_alloc + 1,
what); \
+   d->a = newlen + pre_alloc; \
}\
 }



[2005-04-16 13:08:32] cws at miraclenet dot co dot th

Description:

serialize use a lot of realloc which are very slow on FreeBSD

>From - http://rgarciasuarez.free.fr/p5p/p5p-200307-1.pod -

Dan Kogai explained that FreeBSD comes with an implementation of
malloc()
that is optimized for paged memory, and safe from duplicate free()
calls.
But the downside is that realloc() is very slow. That's usually not a
big
deal, because most programs don't use realloc() very often -- but perl
does. (The default configuration of perl on FreeBSD is to use perl's
internal malloc, that hasn't this realloc limitation.)

Serialize use a fix incremental value (SMART_STR_PREALLOC in
php_smart_ptr.h). It better for serialize to use exponential
incremential value to reduce number of realloc. 






-- 
Edit this bug report at http://bugs.php.net/?id=32727&edit=1


#31175 [NoF->Opn]: MySQL query returns no results when run via PHP

2005-04-18 Thread vortexx at freemail dot hu
 ID:   31175
 User updated by:  vortexx at freemail dot hu
 Reported By:  vortexx at freemail dot hu
-Status:   No Feedback
+Status:   Open
 Bug Type: MySQL related
 Operating System: Windows 2000 Server, SP4
-PHP Version:  5.0.3
+PHP Version:  5.0.4
 New Comment:

Hello again,

I just downloaded PHP 5.0.4 and MySQL 4.1.11, and the same situation
persists as before:

In case of any queries that contain a CONCAT of a string and data from
any MySQL table field, no results are returned via PHP, and also
mysql_error(...) returns no error.


Previous Comments:


[2005-03-08 01:00:20] php-bugs at lists dot php dot net

No feedback was provided for this bug for over a week, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".



[2005-02-28 21:14:11] [EMAIL PROTECTED]

Please try using this CVS snapshot:

  http://snaps.php.net/php5-latest.tar.gz
 
For Windows:
 
  http://snaps.php.net/win32/php5-win32-latest.zip





[2005-02-02 07:36:36] vortexx at freemail dot hu

"a) The table is empty or the where clause didn't match any 
records "
Table was not empty, and there was no WHERE clause. Moreover, the exact
same query prodiced the expected results with PHP versions prior to
5.0.3.

"b) an error occured, which should be checked by 
mysql_error() - in your case probably illegal mix of 
collations."
Did test for an error - please see my original bug report: none
occurred, at least mysql_error returned none.
Also please note: same query (on the exact same database, etc.) works
fine with PHP versions prior to 5.0.3 .

I suspected perhaps this had something to do with the new php_mysql.dll
included with the new (5.0.3+) PHP versions?! Since - ceteris paribus -
the anomaly was directly linked to changing PHP versions. Once I
changed back to the older version, it all worked fine again.

If there is any more info whatsoever that you think might be necessary,
please let me know! THANKS!!!



[2005-02-02 06:48:46] [EMAIL PROTECTED]

If mysql_query doesn't return a resultset for a select 
statement this has 2 reasons: 
a) The table is empty or the where clause didn't match any 
records 
b) an error occured, which should be checked by 
mysql_error() - in your case probably illegal mix of 
collations. 
 
Can't reproduce your error (tested with PHP 4 + 5, MySQL 
4.1.10 and 5.0.3 and different character sets on server 
and client side). 



[2005-02-02 03:58:43] vortexx at freemail dot hu

Sorry, but what do you mean "can't reporduce"? 

That you:
- need more info to be able to do so?
If so, please fire away, let me know what else you need, I would be
glad to provide any info necessary
- tried to reprodice but given the same circumstances the same code
worked fine for you?

Since this is MySQL related obviously I cannot "copy and paste" the
MySQL tables themselves here. I can only give info as to the nature of
tables involved.

To reporoduce just try ANY MySQL query in PHP 5.0.3+ with a CONCAT of a
field from a table plus a string:
SELECT CONCAT('this is a string',field_from_table) as test FROM
whatever_table

The point is that whenever a SELECT with a CONCAT of a string and a
table field is involved, the query returns nothing. If it's just a
CONCAT of 2 or more fields from a table, then it's fine. If it's a
CONCAT of 2 or more strings, no problem. As soon as it is a string plus
a field, no results are returned. BEFORE 5.0.3 the same queries all
worked just fine.

Is this any help? If not, please let me know what info I should send!



The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/31175

-- 
Edit this bug report at http://bugs.php.net/?id=31175&edit=1


#31175 [Opn->Csd]: MySQL query returns no results when run via PHP

2005-04-18 Thread vortexx at freemail dot hu
 ID:   31175
 User updated by:  vortexx at freemail dot hu
 Reported By:  vortexx at freemail dot hu
-Status:   Open
+Status:   Closed
 Bug Type: MySQL related
 Operating System: Windows 2000 Server, SP4
 PHP Version:  5.0.4
 New Comment:

I apologise for the last message. Using PHP 5.0.4 and MySQL 4.1.11 the
problem described in my original post is in fact gone.


Previous Comments:


[2005-04-19 03:14:10] vortexx at freemail dot hu

Hello again,

I just downloaded PHP 5.0.4 and MySQL 4.1.11, and the same situation
persists as before:

In case of any queries that contain a CONCAT of a string and data from
any MySQL table field, no results are returned via PHP, and also
mysql_error(...) returns no error.



[2005-03-08 01:00:20] php-bugs at lists dot php dot net

No feedback was provided for this bug for over a week, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".



[2005-02-28 21:14:11] [EMAIL PROTECTED]

Please try using this CVS snapshot:

  http://snaps.php.net/php5-latest.tar.gz
 
For Windows:
 
  http://snaps.php.net/win32/php5-win32-latest.zip





[2005-02-02 07:36:36] vortexx at freemail dot hu

"a) The table is empty or the where clause didn't match any 
records "
Table was not empty, and there was no WHERE clause. Moreover, the exact
same query prodiced the expected results with PHP versions prior to
5.0.3.

"b) an error occured, which should be checked by 
mysql_error() - in your case probably illegal mix of 
collations."
Did test for an error - please see my original bug report: none
occurred, at least mysql_error returned none.
Also please note: same query (on the exact same database, etc.) works
fine with PHP versions prior to 5.0.3 .

I suspected perhaps this had something to do with the new php_mysql.dll
included with the new (5.0.3+) PHP versions?! Since - ceteris paribus -
the anomaly was directly linked to changing PHP versions. Once I
changed back to the older version, it all worked fine again.

If there is any more info whatsoever that you think might be necessary,
please let me know! THANKS!!!



[2005-02-02 06:48:46] [EMAIL PROTECTED]

If mysql_query doesn't return a resultset for a select 
statement this has 2 reasons: 
a) The table is empty or the where clause didn't match any 
records 
b) an error occured, which should be checked by 
mysql_error() - in your case probably illegal mix of 
collations. 
 
Can't reproduce your error (tested with PHP 4 + 5, MySQL 
4.1.10 and 5.0.3 and different character sets on server 
and client side). 



The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/31175

-- 
Edit this bug report at http://bugs.php.net/?id=31175&edit=1


#32757 [NEW]: file function not allowing multiple underscores in filename

2005-04-18 Thread shawn at shawnfaison dot com
From: shawn at shawnfaison dot com
Operating system: windows NT
PHP version:  4.3.10
PHP Bug Type: Filesystem function related
Bug description:  file function not allowing multiple underscores in filename

Description:

When i attempted this code as follows my var_dump function returned
bool(false).

However after removing the underscores from the csv file the file function
worked just fine.


Reproduce code:
---


Expected result:

/** a var_dump describing the array created by file and the comma
separated values */

array(50) { [0]=>  string(71) "First Name,Last
Name,Weblogin,E-Mail,Pager/Cell,City,State,Webaddress " [1]=>  string(112)
"firstName,lastName,fultonc2,[EMAIL 
PROTECTED],number,AUGUSTA,GA,http:\\www.value.com
" [2]=>  string(95)
"NAOMI,HAMKE,hamken,[EMAIL PROTECTED],,BEDFORD,IN,http:\\www.value.com

Actual result:
--
bool(false)

-- 
Edit bug report at http://bugs.php.net/?id=32757&edit=1
-- 
Try a CVS snapshot (php4):   http://bugs.php.net/fix.php?id=32757&r=trysnapshot4
Try a CVS snapshot (php5.0): 
http://bugs.php.net/fix.php?id=32757&r=trysnapshot50
Try a CVS snapshot (php5.1): 
http://bugs.php.net/fix.php?id=32757&r=trysnapshot51
Fixed in CVS:http://bugs.php.net/fix.php?id=32757&r=fixedcvs
Fixed in release:http://bugs.php.net/fix.php?id=32757&r=alreadyfixed
Need backtrace:  http://bugs.php.net/fix.php?id=32757&r=needtrace
Need Reproduce Script:   http://bugs.php.net/fix.php?id=32757&r=needscript
Try newer version:   http://bugs.php.net/fix.php?id=32757&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=32757&r=support
Expected behavior:   http://bugs.php.net/fix.php?id=32757&r=notwrong
Not enough info: 
http://bugs.php.net/fix.php?id=32757&r=notenoughinfo
Submitted twice: 
http://bugs.php.net/fix.php?id=32757&r=submittedtwice
register_globals:http://bugs.php.net/fix.php?id=32757&r=globals
PHP 3 support discontinued:  http://bugs.php.net/fix.php?id=32757&r=php3
Daylight Savings:http://bugs.php.net/fix.php?id=32757&r=dst
IIS Stability:   http://bugs.php.net/fix.php?id=32757&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=32757&r=gnused
Floating point limitations:  http://bugs.php.net/fix.php?id=32757&r=float
No Zend Extensions:  http://bugs.php.net/fix.php?id=32757&r=nozend
MySQL Configuration Error:   http://bugs.php.net/fix.php?id=32757&r=mysqlcfg


#32757 [Opn]: file function not allowing multiple underscores in filename

2005-04-18 Thread shawn at shawnfaison dot com
 ID:   32757
 User updated by:  shawn at shawnfaison dot com
 Reported By:  shawn at shawnfaison dot com
 Status:   Open
 Bug Type: Filesystem function related
 Operating System: windows NT
 PHP Version:  4.3.10
 New Comment:






Previous Comments:


[2005-04-19 04:26:01] shawn at shawnfaison dot com

Description:

When i attempted this code as follows my var_dump function returned
bool(false).

However after removing the underscores from the csv file the file
function worked just fine.


Reproduce code:
---


Expected result:

/** a var_dump describing the array created by file and the comma
separated values */

array(50) { [0]=>  string(71) "First Name,Last
Name,Weblogin,E-Mail,Pager/Cell,City,State,Webaddress " [1]=> 
string(112)
"firstName,lastName,fultonc2,[EMAIL 
PROTECTED],number,AUGUSTA,GA,http:\\www.value.com
" [2]=>  string(95)
"NAOMI,HAMKE,hamken,[EMAIL PROTECTED],,BEDFORD,IN,http:\\www.value.com

Actual result:
--
bool(false)





-- 
Edit this bug report at http://bugs.php.net/?id=32757&edit=1


#32753 [Opn->Csd]: Undefined Constant SQLite

2005-04-18 Thread iliaa
 ID:   32753
 Updated by:   [EMAIL PROTECTED]
 Reported By:  anthony at drpimp dot com
-Status:   Open
+Status:   Closed
 Bug Type: *Compile Issues
 Operating System: Windows XP
 PHP Version:  5.0.4
 New Comment:

This bug has been fixed in CVS.

Snapshots of the sources are packaged every three hours; this change
will be in the next snapshot. You can grab the snapshot at
http://snaps.php.net/.
 
Thank you for the report, and for helping us make PHP better.




Previous Comments:


[2005-04-18 22:46:07] anthony at drpimp dot com

Description:

Looks like the following constant "SQLITE_NOTADB" is missing from the
source






-- 
Edit this bug report at http://bugs.php.net/?id=32753&edit=1


#32756 [Opn->Bgs]: hacker

2005-04-18 Thread iliaa
 ID:   32756
 Updated by:   [EMAIL PROTECTED]
 Reported By:  jjkjwo at yahoo dot com
-Status:   Open
+Status:   Bogus
 Bug Type: Unknown/Other Function
 Operating System: winxp
 PHP Version:  4.3.11
 New Comment:

as bogus as it gets.


Previous Comments:


[2005-04-19 00:47:39] jjkjwo at yahoo dot com

Description:

www.g00ns.com
Has been hacking various forums, THIS IS A LEGAL ISSUE.
I suggest this company hire a firm and investigate this IMIDIATLY






-- 
Edit this bug report at http://bugs.php.net/?id=32756&edit=1


#32724 [WFx]: sqlite_free_result would be useful for some transaction scenarios

2005-04-18 Thread wez
 ID:   32724
 Updated by:   [EMAIL PROTECTED]
 Reported By:  victor-php at boivie dot com
 Status:   Wont fix
 Bug Type: Feature/Change Request
 Operating System: Not important
 PHP Version:  5.0.4
 New Comment:

The XXX_free and XXX_close functions are redundant and, IMO,
potentially confusing.

Resource types in PHP are reference counted and so are automatically
freed when the refcount falls to zero.  Resources are typically
contained within a zval that has its own refcount.  Variable
assignments bump the zval refcount and not the resource refcount.  This
is ok for most resources; when the zval refcount falls to zero, it
releases the single ref it held on the resource and cleans it up. 
Similarly, the XXX_free functions perform the same action.

When you have a more complicated scenario, with the resource having
more than one reference on it, calling XXX_free will delete only one
reference and not really really free the resource.  This is
counter-intuitive; you would expect that call to free it.  So, it is
better to not have functions that imply such a final act.

Another argument is that $foo = null; is faster to compile and run than
making a function call to foo_free($foo);

In the specific case of sqlite, there should be no problem with a
higher than 1 refcount on a resource, so in theory the function could
be added.  If you add it, people will start using it, and that will
then prompt some backwards compatibility problems in the code that they
are writing.
Since we're focusing on PDO for the future, I'd very much prefer it if
we didn't add this function to the sqlite extension.

--Wez
(the primary author of the sqlite extension)


Previous Comments:


[2005-04-18 07:19:44] victor-php at boivie dot com

I respect your opinion, but might I ask you _what_ your pet hate is?
The SQLite extension? The *_free_result-functions? 

If it is just personal and not for the good of the PHP language, I
might consider implementing it myself (sending a patch to the php-dev
group)



[2005-04-18 01:11:51] [EMAIL PROTECTED]

This is actually one of my pet hates in PHP.
I won't be implementing it.



[2005-04-17 14:54:14] [EMAIL PROTECTED]

moving to the right category..




[2005-04-16 09:10:20] victor-php at boivie dot com

That actually produces correct results. So setting a resource to null
frees the resource? 

http://se2.php.net/manual/en/language.types.resource.php mentions that
"Due to the reference-counting system ... it is automatically detected
when a resource is no longer referred to .. all resources that were in
use for this resource are made free by the garbage collector. For this
reason, it is rarely ever necessary to free the memory manually by
using some free_result function."

So it is actually noted in the manual. However, for symmetry in the PHP
language, I still think it's a good idea to have a sqlite_free_result
that does exactly this, as there is for many other databases (every
other?). It would be more intuitive anyway - what do you think?

Thanks for your help!



[2005-04-16 00:23:56] [EMAIL PROTECTED]

$res = null;

not good enough?



The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/32724

-- 
Edit this bug report at http://bugs.php.net/?id=32724&edit=1


#32330 [Com]: session_destroy, "Failed to initialize storage module", custom session handler

2005-04-18 Thread labsy at seznam dot org
 ID:   32330
 Comment by:   labsy at seznam dot org
 Reported By:  [EMAIL PROTECTED]
 Status:   Assigned
 Bug Type: Session related
 Operating System: *
 PHP Version:  4CVS, 5CVS (2005-03-17)
 Assigned To:  sniper
 New Comment:

I was experiencing this problem one year ago, but now it reoccured.
I run PHP 5.0.2 on Win 2000/IIS
I act as WebHosting provider, host about 170 domains.

Now, one thing that attracted my attention was, that one of my users
installed osCommerce portal few days ago. Since osCommerce handles
sessions its own way, it seems to corrupt session handling function in
PHP all over my server. Any file which has session_start() at the
beginning, needs to be loaded twice, first attempt to load page
produces the mentioned error, but after reload session initializes
normally.

I have
session.save_handler = files
session.save_path = "C:\PHP\sessiondata" ;this dir is world writeable
All my PHP files only use session_start() and $_SESSION[] variable
cals, no other session functions are used.

It worked fine, until one of my users installed osCommerce portal.


Previous Comments:


[2005-03-31 16:37:51] evenh+phpbug at pvv dot ntnu dot no

I experienced this one too, but only when using tavi.sourceforge.net.
This intrigued me, and I've developed a little script to give
information related to this issue.

The script at http://tavi.sourceforge.net/bug32330.php shows a counter
which jumps around at it own free will, seemingly. This due to the
changing host underneath, see changing $_SERVER['SERV_ADDR']. The
script always uses /tmp, and it's always writeable, but it's not on the
same computer!

This could be fixed by using a common path, as is done in
http://tavi.sourceforge.net/bug32330fix.php . And now the counter
works, and I don't get the "Failed to initialize..."-message either. 

The reason for not getting the message, I've experienced, could be
related to accidentially calling session_start() twice... Either in the
same script, or script running in concurrent time space. Or maybe the
lack of session_write_close()?

Note that both the supplied script would include phpinfo() if adding
"?a" (or anything at all) after the script name. The scripts will be
available for some weeks. Feel free to copy them if needed... ;-)

But the messages seems to have gone away, so I'm happy. For now.

Regards,
Even Holen



[2005-03-31 06:33:58] [EMAIL PROTECTED]

I don't see how this relates to my problem besides the error message. I
ask you guys kindly to open a new report about your specific problem.
Your problem has no relation to session handler loosing when calling
session_destroy.



[2005-03-30 17:42:49] todd dot trann at palidar dot com

RedHat 9
PHP 4.3.9 from RPM (php-4.3.9-11.rh90.art)
Zend Engine 1.3.0, Optimizer 2.5.5

I am experiencing the same problem: the error indicates storage module
"user", yet php.ini has it set to "files", and nowhere in my code do I
change it to "user".

The problem comes and goes as the page is reloaded.  A PHP page with no
session code does not exhibit the problem.

Todd



[2005-03-24 22:27:36] scliburn at trtinfo dot com

mfischer,

I'm positive about the session.save_handler and the session_module_name
not being set anywhere.

I'm emailing direct my link to my php info page.
no sessions nothing on the page expect for phpinfo();
the save_handler is set to files. No joke.

another test i've done was to have a copy of a website running on 2
servers (same code, same db)
Server 1: Redhat php 4.3.9 Zend engine 1.3.0 - no problems
Server 2: php 4.3.10 Zend Zend engine 1.3.0 Optimizer 2+ - problems



[2005-03-24 21:43:44] [EMAIL PROTECTED]

Do you use session_destroy in your code? Are you sure you aren't
calling session_module_name somewhere? Does a clean page, with no
session_start but only phpinfo in it, also tell you that the session
module in use is 'user' rather then files?



The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/32330

-- 
Edit this bug report at http://bugs.php.net/?id=32330&edit=1


#32330 [Com]: session_destroy, "Failed to initialize storage module", custom session handler

2005-04-18 Thread labsy at seznam dot org
 ID:   32330
 Comment by:   labsy at seznam dot org
 Reported By:  [EMAIL PROTECTED]
 Status:   Assigned
 Bug Type: Session related
 Operating System: *
 PHP Version:  4CVS, 5CVS (2005-03-17)
 Assigned To:  sniper
 New Comment:

Since this bug is non-persistent, it is very hard to reproduce.

Now, since I run PHP 5.0.2 as ISAPI module, I did a change and added
php5isapi.dll also as ISAPI FILTER under web site properties in IIS.
I don't have a slight idea what would that change, but it seems to
solve problem - I hope.


Previous Comments:


[2005-04-19 07:18:46] labsy at seznam dot org

I was experiencing this problem one year ago, but now it reoccured.
I run PHP 5.0.2 on Win 2000/IIS
I act as WebHosting provider, host about 170 domains.

Now, one thing that attracted my attention was, that one of my users
installed osCommerce portal few days ago. Since osCommerce handles
sessions its own way, it seems to corrupt session handling function in
PHP all over my server. Any file which has session_start() at the
beginning, needs to be loaded twice, first attempt to load page
produces the mentioned error, but after reload session initializes
normally.

I have
session.save_handler = files
session.save_path = "C:\PHP\sessiondata" ;this dir is world writeable
All my PHP files only use session_start() and $_SESSION[] variable
cals, no other session functions are used.

It worked fine, until one of my users installed osCommerce portal.



[2005-03-31 16:37:51] evenh+phpbug at pvv dot ntnu dot no

I experienced this one too, but only when using tavi.sourceforge.net.
This intrigued me, and I've developed a little script to give
information related to this issue.

The script at http://tavi.sourceforge.net/bug32330.php shows a counter
which jumps around at it own free will, seemingly. This due to the
changing host underneath, see changing $_SERVER['SERV_ADDR']. The
script always uses /tmp, and it's always writeable, but it's not on the
same computer!

This could be fixed by using a common path, as is done in
http://tavi.sourceforge.net/bug32330fix.php . And now the counter
works, and I don't get the "Failed to initialize..."-message either. 

The reason for not getting the message, I've experienced, could be
related to accidentially calling session_start() twice... Either in the
same script, or script running in concurrent time space. Or maybe the
lack of session_write_close()?

Note that both the supplied script would include phpinfo() if adding
"?a" (or anything at all) after the script name. The scripts will be
available for some weeks. Feel free to copy them if needed... ;-)

But the messages seems to have gone away, so I'm happy. For now.

Regards,
Even Holen



[2005-03-31 06:33:58] [EMAIL PROTECTED]

I don't see how this relates to my problem besides the error message. I
ask you guys kindly to open a new report about your specific problem.
Your problem has no relation to session handler loosing when calling
session_destroy.



[2005-03-30 17:42:49] todd dot trann at palidar dot com

RedHat 9
PHP 4.3.9 from RPM (php-4.3.9-11.rh90.art)
Zend Engine 1.3.0, Optimizer 2.5.5

I am experiencing the same problem: the error indicates storage module
"user", yet php.ini has it set to "files", and nowhere in my code do I
change it to "user".

The problem comes and goes as the page is reloaded.  A PHP page with no
session code does not exhibit the problem.

Todd



[2005-03-24 22:27:36] scliburn at trtinfo dot com

mfischer,

I'm positive about the session.save_handler and the session_module_name
not being set anywhere.

I'm emailing direct my link to my php info page.
no sessions nothing on the page expect for phpinfo();
the save_handler is set to files. No joke.

another test i've done was to have a copy of a website running on 2
servers (same code, same db)
Server 1: Redhat php 4.3.9 Zend engine 1.3.0 - no problems
Server 2: php 4.3.10 Zend Zend engine 1.3.0 Optimizer 2+ - problems



The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/32330

-- 
Edit this bug report at http://bugs.php.net/?id=32330&edit=1


#32026 [Fbk->Bgs]: Can't call to function with paramArray in arg list definition

2005-04-18 Thread wez
 ID:   32026
 Updated by:   [EMAIL PROTECTED]
 Reported By:  csaba at alum dot mit dot edu
-Status:   Feedback
+Status:   Bogus
 Bug Type: COM related
 Operating System: Win XP Pro
 PHP Version:  5CVS-2005-02-19
 New Comment:

I re-read your report; what you're seeing is the expected behaviour. 
The IDL for your method expects a variant followed by a safearray of
variants.  Both of these are in/out parameters, which means that they
are passed by reference.
Your code was trying to pass constants as parameters, and this  is
illegal (think about it: you can't allow a function to modify a
constant).

PHP can't tell from the IDL that VB has declared the function as having
variable arguments; this concept does not exist in COM, so you must
create an array manually and pass additional arguments in through that
array.



Previous Comments:


[2005-04-18 18:42:58] [EMAIL PROTECTED]

Please paste the IDL for that method into this bug report.
You can view the IDL using the OleView tool.



[2005-02-19 11:09:13] csaba at alum dot mit dot edu

Description:

If I try to make a call to a function where the function has a
paramArray (a VB construct) in the definition, the call fails with (if
the param array gets at least one argument).

For the unfamiliar, a paramArray in VB is an array (of variants) which
consists of all the remaining arguments to the procedure.  As such, it
must be the last declared parameter in the Function declaration.

Csaba Gabor from Vienna


Reproduce code:
---
Here is the PHP test code (menu.php):
ArgCount ("junk", 5, 13);
print $result;
?>


Here is the code for the Menu.OCX file:
Public Function ArgCount(Arg1, ParamArray paArgRest())
'counts the number of arguments passed, excluding Arg1
ArgCount = UBound(paArgRest) + 1 - LBound(paArgRest)
End Function

Notes:
This was built using VB5CCE (the free (while available) VB, Control
Creation Edition)
I have named my control Tool
I have named the Project Menu
I made the OCX into Menu.ocx
In the (VB5CCE) project I went to Project => Menu Properties =>
Component tab and set No Compatibility
After I made Menu.OCX, from the directory Menu.ocx resides in, I did:
regsvr32 Menu.ocx


Here is the corresponding VBScript test file (menu.vbs) that works:
Set oTool = CreateObject("Menu.Tool")
result = oTool.ArgCount("junk", 5, 13)
MsgBox result

Expected result:

I expect to see a 2 printed or displayed (since there are two arguments
after "junk")

Actual result:
--
menu.vbs produces the expected 2.

menu.php file fails with:
Cannot pass parameter 2 by reference in C:\Testing\ParamArray\menu.php
on line 3

If the paramArray gets no elements
$result = $oTool->ArgCount ("junk");
then I get the expected 0

I've inserted a
com_print_typeinfo($oTool) and received (there was other code in
menu.ocx):
/* DISPID=1610809344 */
/* VT_VARIANT [12] */
function ArgCount(
/* VT_PTR [26] [in][out] --> VT_VARIANT [12]  */
&$Arg1,
/* VT_PTR [26] [in][out] --> ? [27]  */ &$paArgRest
)
{
}





-- 
Edit this bug report at http://bugs.php.net/?id=32026&edit=1


#32758 [NEW]: Cannot access safearray properties in VB6 objects

2005-04-18 Thread [EMAIL PROTECTED]
From: [EMAIL PROTECTED]
Operating system: win32
PHP version:  5.0.3
PHP Bug Type: COM related
Bug description:  Cannot access safearray properties in VB6 objects

Description:

echo $obj->arr[3];
on objects written using VB6 would produce the error DISP_E_NOTACOLLECTION
and not allow the data to be accessed.
The same object written using ATL works fine.

Reproduce code:
---
echo $obj->arr[3];

Expected result:

the value

Actual result:
--
a com_exception

-- 
Edit bug report at http://bugs.php.net/?id=32758&edit=1
-- 
Try a CVS snapshot (php4):   http://bugs.php.net/fix.php?id=32758&r=trysnapshot4
Try a CVS snapshot (php5.0): 
http://bugs.php.net/fix.php?id=32758&r=trysnapshot50
Try a CVS snapshot (php5.1): 
http://bugs.php.net/fix.php?id=32758&r=trysnapshot51
Fixed in CVS:http://bugs.php.net/fix.php?id=32758&r=fixedcvs
Fixed in release:http://bugs.php.net/fix.php?id=32758&r=alreadyfixed
Need backtrace:  http://bugs.php.net/fix.php?id=32758&r=needtrace
Need Reproduce Script:   http://bugs.php.net/fix.php?id=32758&r=needscript
Try newer version:   http://bugs.php.net/fix.php?id=32758&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=32758&r=support
Expected behavior:   http://bugs.php.net/fix.php?id=32758&r=notwrong
Not enough info: 
http://bugs.php.net/fix.php?id=32758&r=notenoughinfo
Submitted twice: 
http://bugs.php.net/fix.php?id=32758&r=submittedtwice
register_globals:http://bugs.php.net/fix.php?id=32758&r=globals
PHP 3 support discontinued:  http://bugs.php.net/fix.php?id=32758&r=php3
Daylight Savings:http://bugs.php.net/fix.php?id=32758&r=dst
IIS Stability:   http://bugs.php.net/fix.php?id=32758&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=32758&r=gnused
Floating point limitations:  http://bugs.php.net/fix.php?id=32758&r=float
No Zend Extensions:  http://bugs.php.net/fix.php?id=32758&r=nozend
MySQL Configuration Error:   http://bugs.php.net/fix.php?id=32758&r=mysqlcfg


#32759 [NEW]: incorrect determination of default value

2005-04-18 Thread [EMAIL PROTECTED]
From: [EMAIL PROTECTED]
Operating system: win32
PHP version:  5.0.3
PHP Bug Type: COM related
Bug description:  incorrect determination of default value

Description:

PHP would use the default database binding, rather than the default value
of an object when accessing the implicit value of that object (such as in
casts).


-- 
Edit bug report at http://bugs.php.net/?id=32759&edit=1
-- 
Try a CVS snapshot (php4):   http://bugs.php.net/fix.php?id=32759&r=trysnapshot4
Try a CVS snapshot (php5.0): 
http://bugs.php.net/fix.php?id=32759&r=trysnapshot50
Try a CVS snapshot (php5.1): 
http://bugs.php.net/fix.php?id=32759&r=trysnapshot51
Fixed in CVS:http://bugs.php.net/fix.php?id=32759&r=fixedcvs
Fixed in release:http://bugs.php.net/fix.php?id=32759&r=alreadyfixed
Need backtrace:  http://bugs.php.net/fix.php?id=32759&r=needtrace
Need Reproduce Script:   http://bugs.php.net/fix.php?id=32759&r=needscript
Try newer version:   http://bugs.php.net/fix.php?id=32759&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=32759&r=support
Expected behavior:   http://bugs.php.net/fix.php?id=32759&r=notwrong
Not enough info: 
http://bugs.php.net/fix.php?id=32759&r=notenoughinfo
Submitted twice: 
http://bugs.php.net/fix.php?id=32759&r=submittedtwice
register_globals:http://bugs.php.net/fix.php?id=32759&r=globals
PHP 3 support discontinued:  http://bugs.php.net/fix.php?id=32759&r=php3
Daylight Savings:http://bugs.php.net/fix.php?id=32759&r=dst
IIS Stability:   http://bugs.php.net/fix.php?id=32759&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=32759&r=gnused
Floating point limitations:  http://bugs.php.net/fix.php?id=32759&r=float
No Zend Extensions:  http://bugs.php.net/fix.php?id=32759&r=nozend
MySQL Configuration Error:   http://bugs.php.net/fix.php?id=32759&r=mysqlcfg


#32759 [Opn->Csd]: incorrect determination of default value

2005-04-18 Thread wez
 ID:   32759
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Open
+Status:   Closed
 Bug Type: COM related
 Operating System: win32
 PHP Version:  5.0.3
 New Comment:

This bug has been fixed in CVS.

Snapshots of the sources are packaged every three hours; this change
will be in the next snapshot. You can grab the snapshot at
http://snaps.php.net/.
 
Thank you for the report, and for helping us make PHP better.




Previous Comments:


[2005-04-19 07:56:33] [EMAIL PROTECTED]

Description:

PHP would use the default database binding, rather than the default
value of an object when accessing the implicit value of that object
(such as in casts).






-- 
Edit this bug report at http://bugs.php.net/?id=32759&edit=1


#32758 [Opn->Csd]: Cannot access safearray properties in VB6 objects

2005-04-18 Thread wez
 ID:   32758
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Open
+Status:   Closed
 Bug Type: COM related
 Operating System: win32
 PHP Version:  5.0.3
 New Comment:

This bug has been fixed in CVS.

Snapshots of the sources are packaged every three hours; this change
will be in the next snapshot. You can grab the snapshot at
http://snaps.php.net/.
 
Thank you for the report, and for helping us make PHP better.




Previous Comments:


[2005-04-19 07:52:59] [EMAIL PROTECTED]

Description:

echo $obj->arr[3];
on objects written using VB6 would produce the error
DISP_E_NOTACOLLECTION and not allow the data to be accessed.
The same object written using ATL works fine.

Reproduce code:
---
echo $obj->arr[3];

Expected result:

the value

Actual result:
--
a com_exception





-- 
Edit this bug report at http://bugs.php.net/?id=32758&edit=1


#32757 [Opn->Bgs]: file function not allowing multiple underscores in filename

2005-04-18 Thread sniper
 ID:   32757
 Updated by:   [EMAIL PROTECTED]
 Reported By:  shawn at shawnfaison dot com
-Status:   Open
+Status:   Bogus
 Bug Type: Filesystem function related
 Operating System: windows NT
 PHP Version:  4.3.10
 New Comment:

Thank you for taking the time to report a problem with PHP.
Unfortunately you are not using a current version of PHP -- 
the problem might already be fixed. Please download a new
PHP version from http://www.php.net/downloads.php

If you are able to reproduce the bug with one of the latest
versions of PHP, please change the PHP version on this bug report
to the version you tested and change the status back to "Open".
Again, thank you for your continued support of PHP.




Previous Comments:


[2005-04-19 04:26:01] shawn at shawnfaison dot com

Description:

When i attempted this code as follows my var_dump function returned
bool(false).

However after removing the underscores from the csv file the file
function worked just fine.


Reproduce code:
---


Expected result:

/** a var_dump describing the array created by file and the comma
separated values */

array(50) { [0]=>  string(71) "First Name,Last
Name,Weblogin,E-Mail,Pager/Cell,City,State,Webaddress " [1]=> 
string(112)
"firstName,lastName,fultonc2,[EMAIL 
PROTECTED],number,AUGUSTA,GA,http:\\www.value.com
" [2]=>  string(95)
"NAOMI,HAMKE,hamken,[EMAIL PROTECTED],,BEDFORD,IN,http:\\www.value.com

Actual result:
--
bool(false)





-- 
Edit this bug report at http://bugs.php.net/?id=32757&edit=1


#32752 [Opn->Bgs]: Unable to load dynamic library and signal Segmentation fault

2005-04-18 Thread sniper
 ID:   32752
 Updated by:   [EMAIL PROTECTED]
 Reported By:  dcvoyager at gmail dot com
-Status:   Open
+Status:   Bogus
-Bug Type: Reproducible crash
+Bug Type: Dynamic loading
 Operating System: Red Hat enterprise Linuxe ES 3
 PHP Version:  5.0.4
 New Comment:

Sorry, but your problem does not imply a bug in PHP itself.  For a
list of more appropriate places to ask for help using PHP, please
visit http://www.php.net/support.php as this bug system is not the
appropriate forum for asking support questions.  Due to the volume
of reports we can not explain in detail here why your report is not
a bug.  The support channels will be able to provide an explanation
for you.

Thank you for your interest in PHP.




Previous Comments:


[2005-04-19 00:13:37] dcvoyager at gmail dot com

Now I get these errors in httpd error log after changing the extension
dir in php.ini apart and also this 

[Mon Apr 18 15:08:08 2005] [notice] child pid 25188 exit signal
Segmentation fault (11)

PHP Warning:  PHP Startup: : Unable to initialize module!Module
compiled with module API=20020429, debug=0, 

thread-safety=0!PHPcompiled with module API=20041030, debug=0,
thread-safety=0!These options need to match! in Unknown on line 0
PHP Warning:  PHP Startup: !M!!: Unable to initialize module!Module
compiled with module API=20020429, debug=0, 
thread-safety=0!PHPcompiled with module API=20041030, debug=0,
thread-safety=0!These options need to match! in Unknown on 

line 0
PHP Warning:  PHP Startup:  V!!: Unable to initialize module!Module
compiled with module API=20020429, debug=0, 

thread-safety=0!PHPcompiled with module API=20041030, debug=0,
thread-safety=0!These options need to match! in Unknown on 

line 0
PHP Warning:  PHP Startup: !]!!: Unable to initialize module!Module
compiled with module API=20020429, debug=0, 

thread-safety=0!PHPcompiled with module API=20041030, debug=0,
thread-safety=0!These options need to match! in Unknown on 

line 0
PHP Warning:  PHP Startup: : Unable to initialize module!Module
compiled with module API=20020429, debug=0, 

thread-safety=0!PHPcompiled with module API=20041030, debug=0,
thread-safety=0!These options need to match! in Unknown on 

line 0



[2005-04-18 22:34:01] dcvoyager at gmail dot com

Description:

I have redhat enterprise (ES) version 3 and I had php-4.3.2-19.ent
instaled on it with httpd-2.0.46-44.ent and mysql-4.1.11.

I upgraded my php to 5.0.4 and my configure was 
./configure --prefix=/usr \
--exec-prefix=/usr \
--bindir=/usr/bin \
--sbindir=/usr/sbin \
--sysconfdir=/etc \
--datadir=/usr/share \
--includedir=/usr/include \
--libdir=/usr/lib \
--libexecdir=/usr/libexec \
--localstatedir=/var \
--sharedstatedir=/usr/com \
--mandir=/usr/share/man \
--infodir=/usr/share/info \
--cache-file=../config.cache \
--with-config-file-path=/etc \
--with-config-file-scan-dir=/etc/php.d \
--enable-force-cgi-redirect \
--disable-debug \
--enable-pic \
--disable-rpath \
--enable-inline-optimization \
--with-bz2 \
--with-db4=/usr \
--with-curl \
--with-dom=/usr \
--with-exec-dir=/usr/bin \
--with-freetype-dir=/usr \
--with-png-dir=/usr \
--with-gd \
--enable-gd-native-ttf \
--with-ttf \
--with-gettext \
--with-ncurses \
--with-gmp \
--with-iconv \
--with-jpeg-dir=/usr \
--with-openssl \
--with-png \
--with-pspell \
--with-regex=system \
--with-xml \
--with-expat-dir=/usr \
--with-pcre-regex=/usr \
--with-zlib \
--with-layout=GNU \
--enable-bcmath \
--enable-exif \
--enable-ftp \
--enable-magic-quotes \
--enable-safe-mode \
--enable-sockets \
--enable-sysvsem \
--enable-sysvshm \
--enable-discard-path \
--enable-track-vars \
--enable-trans-sid \
--enable-yp \
--enable-wddx \
--enable-mbstring \
--enable-mbstr-enc-trans \
--enable-mbregex \
--without-oci8 \
--with-pear=/usr/share/pear \
--with-imap=shared --with-imap-ssl \
--with-kerberos=/usr/kerberos \
--with-ldap=shared \
--with-mysql=shared,/usr \
--with-pgsql=shared \
--with-unixODBC=shared \
--enable-memory-limit \
--enable-bcmath \
--enable-shmop \
--enable-versioning \
--enable-calendar \
--enable-dbx \
--enable-dio \
--enable-mcal \
--with-apxs2filter=/usr/sbin/apxs

after the make and make install, I restarted apache, now none of my php
scripst works. When I looked at the error logs for httpd it gives this
error
[**error*]
[Mon Apr 18 15:08:08 2005] [notice] child pid 25188 exit signal
Segmentation fault (11) 

and also these errors

PHP Warning:  PHP Startup: : Unable to initialize module
Module compiled with module API=20020429, debug=0, thread-safety=0
PHPcompiled with module API=20041030, debug=0, thread-safety=0
These options need to match
 in Unknown on line 0
PHP Warning:  PHP Startup: Unable to load dynamic library
'/usr/lib/php4/ldap.so' - /usr/lib/php4/ldap.so: un

#32751 [Opn->Fbk]: Segfault after code execution (destructor calls)

2005-04-18 Thread sniper
 ID:   32751
 Updated by:   [EMAIL PROTECTED]
 Reported By:  prism at pld-linux dot org
-Status:   Open
+Status:   Feedback
 Bug Type: Zend Engine 2 problem
 Operating System: PLD Linux Distribution
 PHP Version:  5.0.4
 New Comment:

Not enough information was provided for us to be able
to handle this bug. Please re-read the instructions at
http://bugs.php.net/how-to-report.php

If you can provide more information, feel free to add it
to this bug and change the status back to "Open".

Thank you for your interest in PHP.





Previous Comments:


[2005-04-18 21:49:05] prism at pld-linux dot org

Description:

Zend engine or all modules which use persistent_list. 
persistent_list is destroyed after modules are unloaded. 
But some modules register own destructors for elements put 
on 
persistent_list. When Zend destroys such entry from 
persistent_list, 
it tries to call destructor from unloaded module and 
segfaults. 

Reproduce code:
---
Look here: http://comments.gmane.org/gmane.linux.pld.devel.english/785
and start reading from post written at 16 Apr 17:33 by Michal Lukaszek,
and below from that.

Expected result:

No segfault. 

Actual result:
--
> (gdb) bt 
> #0  0xb78a6978 in ?? () 
> #1  0xb7f557da in plist_entry_destructor (ptr=0x81e11b8) 
> 
at /home/comp/rpm/BUILD/php-5.0.4/Zend/zend_list.c:204 
> #2  0xb7f5385f in zend_hash_apply_deleter (ht=0x8052c50, 
p=0x81ec1a0) 
> 
at /home/comp/rpm/BUILD/php-5.0.4/Zend/zend_hash.c:574 
> #3  0xb7f53ab0 in zend_hash_graceful_reverse_destroy 
(ht=0x8052c50) 
> 
at /home/comp/rpm/BUILD/php-5.0.4/Zend/zend_hash.c:640 
> #4  0xb7f558f6 in zend_destroy_rsrc_list (ht=0x8052c50, 
tsrm_ls=0x804f0a0) 
> 
at /home/comp/rpm/BUILD/php-5.0.4/Zend/zend_list.c:234 
> #5  0xb7f49c20 in zend_shutdown (tsrm_ls=0x804f0a0) 
> at /home/comp/rpm/BUILD/php-5.0.4/Zend/zend.c:714 
> #6  0xb7ef42d5 in php_module_shutdown 
(tsrm_ls=0x804f0a0) 
> at /home/comp/rpm/BUILD/php-5.0.4/main/main.c:1518 
> #7  0x0804be1e in main (argc=2, argv=0xb174) 
> 
at /home/comp/rpm/BUILD/php-5.0.4/sapi/cli/php_cli.c:1055 
> (gdb) f 1 
> #1  0xb7f557da in plist_entry_destructor (ptr=0x81e11b8) 
> 
at /home/comp/rpm/BUILD/php-5.0.4/Zend/zend_list.c:204 
> 204 
ld->plist_dtor_ex(le TSRMLS_CC); 
> (gdb) p ld->plist_dtor_ex 
> $1 = 0xb78a6978 
> (gdb) x ld->plist_dtor_ex 
> 0xb78a6978: Cannot access memory at address 
0xb78a6978 
 
it's in (unloaded) php-mysql module 
 
> The list here is "persistent_list", which is used by 
php-mysql for 
> persistent connection - so it's probably bug in 
php-mysql module or php 
> engine itself. 





-- 
Edit this bug report at http://bugs.php.net/?id=32751&edit=1