#35176 [Opn]: include()/require()/*_once() produce wrong error messages about main()

2005-11-10 Thread vrana
 ID:   35176
 Updated by:   [EMAIL PROTECTED]
 Reported By:  subscription at nazarenko dot net
 Status:   Open
-Bug Type: Documentation problem
+Bug Type: PHP options/info functions
 Operating System: SuSE Linux 10.0
 PHP Version:  5CVS-2005-11-09 (CVS)
 New Comment:

I removed the "No longer points here" column from function.main in
CVS.

This is maybe not easy to fix but it's still a bug:

1. Prior to function.require error message, there's a bogus
function.main error message - it should be silented.

2. require_once() points to function.require and not
function.require-once, include_once() parallel.


Previous Comments:


[2005-11-10 09:23:11] [EMAIL PROTECTED]

See also bug #21499.



[2005-11-09 22:32:11] [EMAIL PROTECTED]

The docs are wrong - I can see the same problem in 4.3.6 and 4.3.10.
Also, I don't see an easy way to fix it, since include_*()/require_*()
aren't really functions, but language constructs. 



[2005-11-09 22:14:54] subscription at nazarenko dot net

Sorry, the script above should have

require_once('fake');



[2005-11-09 22:06:47] subscription at nazarenko dot net

A sample script:



Produces this HTML (html_errors=on):

Warning:  main(fake) [function.main.php]:
failed to open stream: No such file or directory in x.php on line
2


Fatal error:  main() [function.require.php]:
Failed opening required 'fake' (include_path='.:/usr/lib/php') in
x.php on line 2


This illustrates both points:  the erroneous main() function as well as
the wrong html link  (should be funtion.require-once.php)



[2005-11-09 21:56:51] [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.





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/35176

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


#35140 [Fbk->Opn]: Segmentation fault in shutdown_memory_manager

2005-11-10 Thread jfbustarret at tf1 dot fr
 ID:   35140
 User updated by:  jfbustarret at tf1 dot fr
 Reported By:  jfbustarret at tf1 dot fr
-Status:   Feedback
+Status:   Open
 Bug Type: Reproducible crash
 Operating System: Linux
 PHP Version:  5.0.5
 New Comment:

With/without --enable-debug, php5-latests crashes in :

#0  0x4075c447 in _zend_hash_index_update_or_next_insert
(ht=0x4089cd40, h=0,
pData=0xbfee8100, nDataSize=12, pDest=0x0, flag=Variable "flag" is
not available.
)
at /soft/sources/php/php5-200511100730/Zend/zend_hash.c:354
#1  0x4075dc42 in zend_list_insert (ptr=0x0, type=0)
at /soft/sources/php/php5-200511100730/Zend/zend_list.c:47
#2  0x4075dc67 in zend_register_resource (rsrc_result=0x0,
rsrc_pointer=0x830b10c, rsrc_type=2)
at /soft/sources/php/php5-200511100730/Zend/zend_list.c:99
#3  0x4072b228 in _php_stream_alloc (ops=0x0, abstract=0x0,
persistent_id=0x0,
mode=0x407cafb7 "rb", __php_stream_call_depth=5,
__zend_filename=0x40806e28
"/soft/sources/php/php5-200511100730/main/streams/plain_wrapper.c",
__zend_lineno=205,
__zend_orig_filename=0x408048d4
"/soft/sources/php/php5-200511100730/main/main.c",
__zend_orig_lineno=855)
at /soft/sources/php/php5-200511100730/main/streams/streams.c:263
#4  0x4072e9c3 in _php_stream_fopen_from_fd (fd=27, mode=0x407cafb7
"rb",
persistent_id=0x0, __php_stream_call_depth=4,
__zend_filename=0x40806e28
"/soft/sources/php/php5-200511100730/main/streams/plain_wrapper.c",
__zend_lineno=882,
__zend_orig_filename=0x408048d4
"/soft/sources/php/php5-200511100730/main/main.c",
__zend_orig_lineno=855)
at
/soft/sources/php/php5-200511100730/main/streams/plain_wrapper.c:205
#5  0x4072eb40 in _php_stream_fopen (
filename=0x83170a8 "/data/www/www/htdocs/src/affichePage.php",
mode=0x407cafb7 "rb", opened_path=0xbfee95f8, options=133,
__php_stream_call_depth=3,
__zend_filename=0x40806e28
"/soft/sources/php/php5-200511100730/main/streams/plain_wrapper.c",
__zend_lineno=1233,
__zend_orig_filename=0x408048d4
"/soft/sources/php/php5-200511100730/main/ma---Type  to
continue, or q  to quit---
in.c", __zend_orig_lineno=855)
at
/soft/sources/php/php5-200511100730/main/streams/plain_wrapper.c:882
#6  0x4072ed65 in _php_stream_fopen_with_path (
filename=0x83170a8 "/data/www/www/htdocs/src/affichePage.php",
mode=0x407cafb7 "rb",
path=0x82ec2e4
"/data/www/commons/commons:/data/www/www/htdocs/src:/data/www/commons/PEAR:/data/www/commons/conf:/data/www/www/conf:.",
opened_path=0xbfee95f8, options=133, __php_stream_call_depth=2,
__zend_filename=0x40806e28
"/soft/sources/php/php5-200511100730/main/streams/plain_wrapper.c",
__zend_lineno=931,
__zend_orig_filename=0x408048d4
"/soft/sources/php/php5-200511100730/main/main.c",
__zend_orig_lineno=855)
at
/soft/sources/php/php5-200511100730/main/streams/plain_wrapper.c:1276
#7  0x4072b525 in _php_stream_open_wrapper_ex (
path=0x83170a8 "/data/www/www/htdocs/src/affichePage.php",
mode=0x407cafb7 "rb", options=141, opened_path=0xbfee95f8,
context=0x0,
__php_stream_call_depth=0,
__zend_filename=0x408048d4
"/soft/sources/php/php5-200511100730/main/main.c", __zend_lineno=855,
__zend_orig_filename=0x0, __zend_orig_lineno=0)
at /soft/sources/php/php5-200511100730/main/streams/streams.c:1771
#8  0x407186d3 in php_stream_open_for_zend (
filename=0x83170a8 "/data/www/www/htdocs/src/affichePage.php",
handle=0xbfee95f0) at
/soft/sources/php/php5-200511100730/main/main.c:855
#9  0x40763a6a in zend_stream_open (
filename=0x83170a8 "/data/www/www/htdocs/src/affichePage.php",
handle=0xbfee95f0)
at /soft/sources/php/php5-200511100730/Zend/zend_stream.c:47
#10 0x40763bc0 in zend_stream_fixup (file_handle=0xbfee95f0)
at /soft/sources/php/php5-200511100730/Zend/zend_stream.c:62
---Type  to continue, or q  to quit---
#11 0x4073c010 in open_file_for_scanning (file_handle=0xbfee95f0)
at zend_language_scanner.c:3070
#12 0x4073c6e9 in compile_file (file_handle=0xbfee95f0, type=2)
at zend_language_scanner.c:3156
#13 0x4075256c in zend_execute_scripts (type=2, retval=0x0,
file_count=1)
at /soft/sources/php/php5-200511100730/Zend/zend.c:1079

(gdb) print ht
$1 = (HashTable *) 0x4089cd40
(gdb) print *ht
$2 = {nTableSize = 0, nTableMask = 0, nNumOfElements = 0,
  nNextFreeElement = 0, pInternalPointer = 0x0, pListHead = 0x0,
  pListTail = 0x0, arBuckets = 0x0, pDestructor = 0, persistent = 0
'\0',
  nApplyCount = 0 '\0', bApplyProtection = 0 '\0', inconsistent = 0}


Previous Comments:


[2005-11-07 18:02: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-11-07 16:34:24] jfbustarret at tf1 dot fr

Description:

Sometimes, some apach

#35140 [Opn->Fbk]: Segmentation fault in shutdown_memory_manager

2005-11-10 Thread sniper
 ID:   35140
 Updated by:   [EMAIL PROTECTED]
 Reported By:  jfbustarret at tf1 dot fr
-Status:   Open
+Status:   Feedback
-Bug Type: Reproducible crash
+Bug Type: Scripting Engine problem
 Operating System: Linux
-PHP Version:  5.0.5
+PHP Version:  5CVS-2005-11-10 (snap)
 New Comment:

Do you load those shared extensions in your php.ini?
Can you try without them? And what is the shortest possible configure
line you can reproduce this with?


Previous Comments:


[2005-11-10 10:31:56] jfbustarret at tf1 dot fr

With/without --enable-debug, php5-latests crashes in :

#0  0x4075c447 in _zend_hash_index_update_or_next_insert
(ht=0x4089cd40, h=0,
pData=0xbfee8100, nDataSize=12, pDest=0x0, flag=Variable "flag" is
not available.
)
at /soft/sources/php/php5-200511100730/Zend/zend_hash.c:354
#1  0x4075dc42 in zend_list_insert (ptr=0x0, type=0)
at /soft/sources/php/php5-200511100730/Zend/zend_list.c:47
#2  0x4075dc67 in zend_register_resource (rsrc_result=0x0,
rsrc_pointer=0x830b10c, rsrc_type=2)
at /soft/sources/php/php5-200511100730/Zend/zend_list.c:99
#3  0x4072b228 in _php_stream_alloc (ops=0x0, abstract=0x0,
persistent_id=0x0,
mode=0x407cafb7 "rb", __php_stream_call_depth=5,
__zend_filename=0x40806e28
"/soft/sources/php/php5-200511100730/main/streams/plain_wrapper.c",
__zend_lineno=205,
__zend_orig_filename=0x408048d4
"/soft/sources/php/php5-200511100730/main/main.c",
__zend_orig_lineno=855)
at /soft/sources/php/php5-200511100730/main/streams/streams.c:263
#4  0x4072e9c3 in _php_stream_fopen_from_fd (fd=27, mode=0x407cafb7
"rb",
persistent_id=0x0, __php_stream_call_depth=4,
__zend_filename=0x40806e28
"/soft/sources/php/php5-200511100730/main/streams/plain_wrapper.c",
__zend_lineno=882,
__zend_orig_filename=0x408048d4
"/soft/sources/php/php5-200511100730/main/main.c",
__zend_orig_lineno=855)
at
/soft/sources/php/php5-200511100730/main/streams/plain_wrapper.c:205
#5  0x4072eb40 in _php_stream_fopen (
filename=0x83170a8 "/data/www/www/htdocs/src/affichePage.php",
mode=0x407cafb7 "rb", opened_path=0xbfee95f8, options=133,
__php_stream_call_depth=3,
__zend_filename=0x40806e28
"/soft/sources/php/php5-200511100730/main/streams/plain_wrapper.c",
__zend_lineno=1233,
__zend_orig_filename=0x408048d4
"/soft/sources/php/php5-200511100730/main/ma---Type  to
continue, or q  to quit---
in.c", __zend_orig_lineno=855)
at
/soft/sources/php/php5-200511100730/main/streams/plain_wrapper.c:882
#6  0x4072ed65 in _php_stream_fopen_with_path (
filename=0x83170a8 "/data/www/www/htdocs/src/affichePage.php",
mode=0x407cafb7 "rb",
path=0x82ec2e4
"/data/www/commons/commons:/data/www/www/htdocs/src:/data/www/commons/PEAR:/data/www/commons/conf:/data/www/www/conf:.",
opened_path=0xbfee95f8, options=133, __php_stream_call_depth=2,
__zend_filename=0x40806e28
"/soft/sources/php/php5-200511100730/main/streams/plain_wrapper.c",
__zend_lineno=931,
__zend_orig_filename=0x408048d4
"/soft/sources/php/php5-200511100730/main/main.c",
__zend_orig_lineno=855)
at
/soft/sources/php/php5-200511100730/main/streams/plain_wrapper.c:1276
#7  0x4072b525 in _php_stream_open_wrapper_ex (
path=0x83170a8 "/data/www/www/htdocs/src/affichePage.php",
mode=0x407cafb7 "rb", options=141, opened_path=0xbfee95f8,
context=0x0,
__php_stream_call_depth=0,
__zend_filename=0x408048d4
"/soft/sources/php/php5-200511100730/main/main.c", __zend_lineno=855,
__zend_orig_filename=0x0, __zend_orig_lineno=0)
at /soft/sources/php/php5-200511100730/main/streams/streams.c:1771
#8  0x407186d3 in php_stream_open_for_zend (
filename=0x83170a8 "/data/www/www/htdocs/src/affichePage.php",
handle=0xbfee95f0) at
/soft/sources/php/php5-200511100730/main/main.c:855
#9  0x40763a6a in zend_stream_open (
filename=0x83170a8 "/data/www/www/htdocs/src/affichePage.php",
handle=0xbfee95f0)
at /soft/sources/php/php5-200511100730/Zend/zend_stream.c:47
#10 0x40763bc0 in zend_stream_fixup (file_handle=0xbfee95f0)
at /soft/sources/php/php5-200511100730/Zend/zend_stream.c:62
---Type  to continue, or q  to quit---
#11 0x4073c010 in open_file_for_scanning (file_handle=0xbfee95f0)
at zend_language_scanner.c:3070
#12 0x4073c6e9 in compile_file (file_handle=0xbfee95f0, type=2)
at zend_language_scanner.c:3156
#13 0x4075256c in zend_execute_scripts (type=2, retval=0x0,
file_count=1)
at /soft/sources/php/php5-200511100730/Zend/zend.c:1079

(gdb) print ht
$1 = (HashTable *) 0x4089cd40
(gdb) print *ht
$2 = {nTableSize = 0, nTableMask = 0, nNumOfElements = 0,
  nNextFreeElement = 0, pInternalPointer = 0x0, pListHead = 0x0,
  pListTail = 0x0, arBuckets = 0x0, pDestructor = 0, persistent = 0
'\0',
  nApplyCount = 0 '\0', bApplyProtection = 0 '\0', inconsistent = 0}



[2

#35062 [Asn->Opn]: [PATCH] socket_read() produces warnings on non blocking sockets

2005-11-10 Thread nlopess
 ID:   35062
 Updated by:   [EMAIL PROTECTED]
 Reported By:  dima at dimych dot sumy dot ua
-Status:   Assigned
+Status:   Open
 Bug Type: Sockets related
 Operating System: *
 PHP Version:  5CVS, 4CVS (2005-11-10) (cvs)
 Assigned To:  nlopess
 New Comment:

Ok, I've sent an e-mail to internals ML.
But I cannot commit the patch, because I don't have enough karma.


Previous Comments:


[2005-11-10 08:45:30] [EMAIL PROTECTED]

Nuno, I think you will only get some feedback on your patch if  you
either commit it, or post it to internals list.



[2005-11-10 00:17:12] [EMAIL PROTECTED]

After the reading the bug report carefully, the only problem here is
that socket_read() shouldn't produce a warning when errno==EAGAIN. The
return value of the function doesn't need/can't be changed.

The constant SOCKET_EAGAIN is already defined, so there's also a doc
bug :) (all SOCKET_* need to be documented)

The patch: http://mega.ist.utl.pt/~ncpl/php_bug_35062.txt



[2005-11-05 22:13:26] [EMAIL PROTECTED]

opening it again, as this seems a different issue.
We should have the EAGAIN constant and use it for non-blocking sockets.
returning false isnt't a good idea.



[2005-11-04 16:23:08] [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.

See bug #21197



[2005-11-04 14:53:52] dima at dimych dot sumy dot ua

I`m look everyware in the Internet and don`t find any workaround for
this problem. And error logs still growing...

This code decreases count of warnings:
-- code --
$startTime = microtime_float(true);
socket_send($socket, $package, strLen($package), 0);
socket_set_block($socket);
$to = array('sec' => 0, 'usec' => 50);
socket_set_option($socket, SOL_SOCKET, SO_RCVTIMEO, $to);
if (socket_read($socket, 4096)) {
  socket_close($socket);
  return microtime_float() - $startTime;
}
socket_close($socket);
-- end of code --
my "ping" function launches once per 5 minutes for around 50 hosts, but
not all of them alive. Dead hosts causes warnings.



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/35062

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


#35140 [Fbk->Opn]: Segmentation fault in shutdown_memory_manager

2005-11-10 Thread jfbustarret at tf1 dot fr
 ID:   35140
 User updated by:  jfbustarret at tf1 dot fr
 Reported By:  jfbustarret at tf1 dot fr
-Status:   Feedback
+Status:   Open
 Bug Type: Scripting Engine problem
 Operating System: Linux
 PHP Version:  5CVS-2005-11-10 (snap)
 New Comment:

With :
'./configure' '--with-apxs2=/usr/sbin/apxs2'
'--with-config-file-path=/etc' '--with-oci8=/soft/ora920'
'--prefix=/soft/php-5-200511100730-20051110-debug'
'--exec-prefix=/soft/php-5-200511100730-20051110-debug'
'--without-pear' '--with-mysql=/usr'
'--with-mysql-sock=/tmp/mysql.sock' 'CFLAGS=-O2 -g'

I get this crash :
#0  0x4070f068 in zend_clear_exception ()
at /soft/sources/php/php5-200511100730/Zend/zend_exceptions.c:68
68  if (!EG(exception)) {
(gdb) bt
#0  0x4070f068 in zend_clear_exception ()
at /soft/sources/php/php5-200511100730/Zend/zend_exceptions.c:68
#1  0x4071050d in zif_exception_getLine ()
at /soft/sources/php/php5-200511100730/Zend/zend_exceptions.c:220
#2  0x4083acf8 in ?? ()
[snip]
#16 0xbf9233e8 in ?? ()
#17 0x40710537 in zif_exception_getFile (ht=137277364,
return_value=0x2,
return_value_ptr=0x3a97, this_ptr=0x0,
return_value_used=137147524)
at /soft/sources/php/php5-200511100730/Zend/zend_exceptions.c:209
#18 0x40710537 in zif_exception_getFile (ht=0, return_value=0x82eafb4,
return_value_ptr=0x2, this_ptr=0x0, return_value_used=86073)
at /soft/sources/php/php5-200511100730/Zend/zend_exceptions.c:209
#19 0x406e2639 in zendparse () at zend_language_parser.c:4333
[snip]
(gdb) print executor_globals.exception
$1 = (zval *) 0x44238317
(gdb) print *executor_globals.exception
Cannot access memory at address 0x44238317

With more extensions, I have various crashes, like this one :
#0  0x406ed5fd in yy_push_state (new_state=1) at
zend_language_scanner.c:6029
#1  0x406edfe7 in lex_scan (zendlval=0xbf8163d4)
at zend_language_scanner.c:4418

I'll try the same with PHP-5.0.5.


Previous Comments:


[2005-11-10 10:52:37] [EMAIL PROTECTED]

Do you load those shared extensions in your php.ini?
Can you try without them? And what is the shortest possible configure
line you can reproduce this with?



[2005-11-10 10:31:56] jfbustarret at tf1 dot fr

With/without --enable-debug, php5-latests crashes in :

#0  0x4075c447 in _zend_hash_index_update_or_next_insert
(ht=0x4089cd40, h=0,
pData=0xbfee8100, nDataSize=12, pDest=0x0, flag=Variable "flag" is
not available.
)
at /soft/sources/php/php5-200511100730/Zend/zend_hash.c:354
#1  0x4075dc42 in zend_list_insert (ptr=0x0, type=0)
at /soft/sources/php/php5-200511100730/Zend/zend_list.c:47
#2  0x4075dc67 in zend_register_resource (rsrc_result=0x0,
rsrc_pointer=0x830b10c, rsrc_type=2)
at /soft/sources/php/php5-200511100730/Zend/zend_list.c:99
#3  0x4072b228 in _php_stream_alloc (ops=0x0, abstract=0x0,
persistent_id=0x0,
mode=0x407cafb7 "rb", __php_stream_call_depth=5,
__zend_filename=0x40806e28
"/soft/sources/php/php5-200511100730/main/streams/plain_wrapper.c",
__zend_lineno=205,
__zend_orig_filename=0x408048d4
"/soft/sources/php/php5-200511100730/main/main.c",
__zend_orig_lineno=855)
at /soft/sources/php/php5-200511100730/main/streams/streams.c:263
#4  0x4072e9c3 in _php_stream_fopen_from_fd (fd=27, mode=0x407cafb7
"rb",
persistent_id=0x0, __php_stream_call_depth=4,
__zend_filename=0x40806e28
"/soft/sources/php/php5-200511100730/main/streams/plain_wrapper.c",
__zend_lineno=882,
__zend_orig_filename=0x408048d4
"/soft/sources/php/php5-200511100730/main/main.c",
__zend_orig_lineno=855)
at
/soft/sources/php/php5-200511100730/main/streams/plain_wrapper.c:205
#5  0x4072eb40 in _php_stream_fopen (
filename=0x83170a8 "/data/www/www/htdocs/src/affichePage.php",
mode=0x407cafb7 "rb", opened_path=0xbfee95f8, options=133,
__php_stream_call_depth=3,
__zend_filename=0x40806e28
"/soft/sources/php/php5-200511100730/main/streams/plain_wrapper.c",
__zend_lineno=1233,
__zend_orig_filename=0x408048d4
"/soft/sources/php/php5-200511100730/main/ma---Type  to
continue, or q  to quit---
in.c", __zend_orig_lineno=855)
at
/soft/sources/php/php5-200511100730/main/streams/plain_wrapper.c:882
#6  0x4072ed65 in _php_stream_fopen_with_path (
filename=0x83170a8 "/data/www/www/htdocs/src/affichePage.php",
mode=0x407cafb7 "rb",
path=0x82ec2e4
"/data/www/commons/commons:/data/www/www/htdocs/src:/data/www/commons/PEAR:/data/www/commons/conf:/data/www/www/conf:.",
opened_path=0xbfee95f8, options=133, __php_stream_call_depth=2,
__zend_filename=0x40806e28
"/soft/sources/php/php5-

#32330 [Com]: session_destroy, "Failed to initialize storage module", custom session handler

2005-11-10 Thread ts at dreamcoder dot dk
 ID:   32330
 Comment by:   ts at dreamcoder dot dk
 Reported By:  [EMAIL PROTECTED]
 Status:   Open
 Bug Type: Session related
 Operating System: *
 PHP Version:  5CVS, 4CVS (2005-03-17)
 New Comment:

This bug is still very much causing problems.
Without knowing about the code side of it, this bug reminds me of the
php_value leak there was amoung virtualhosts in apache once - where the
value from one virtualhost was leaked in to another.

Manually adding ini_set('session.save_handler', 'files') to the top of
PHP files, solves the problem.


Previous Comments:


[2005-06-04 00:25:54] [EMAIL PROTECTED]

PS(mod_data) gets set to NULL with these:

session_write_close(),
session_module_name('foo'),
session_destroy()







[2005-05-21 19:19:42] [EMAIL PROTECTED]

I think you are on the right track mfischer.  It looks like PS(mod) and
PS(mod_data) can get out of synch which would cause this.  And I think
all the others with seemingly unrelated issues are actually related. 
If PS(mod_data) leaks out of the per-request sandbox and infects
subsequent requests all it takes is one application on a server to use
its own session handler and it could affect other seemingly trivial
standalone session apps on that server.



[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-17 10:37:29] [EMAIL PROTECTED]

I see that the php_session_destroy() is called in php_session_decode()
too..




[2005-03-17 10:14:08] [EMAIL PROTECTED]

I unfortunately lack the time to verify this with a new php
installation currently.

By looking at
http://cvs.php.net/co.php/php-src/ext/session/session.c?r=1.336.2.50
(latest commit of 4_3 branch) the relevant parts of the code haven't
changed. PS(mod_data) is still set to NULL in php_rinit_session_globals
which is called from php_session_destroy, this when a user from PHP
calls session_destroy(), the custom session save handlers are removed.

Thanks



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


#35182 [NEW]: Successfully loaded, but cannot use Mysqli functions/class

2005-11-10 Thread webmaster at mif dot it
From: webmaster at mif dot it
Operating system: Win XP Pro
PHP version:  5.0.5
PHP Bug Type: MySQLi related
Bug description:  Successfully loaded, but cannot use Mysqli functions/class

Description:

Cannot use Mysqli functions, without using references.

Reproduce code:
---
This code:
$db = mysqli_connect('localhost','Matteo','teo28273');
and this doesn't works:
$db = new mysqli('localhost','Matteo','teo28273');

This code:
$db =& mysqli_connect('localhost','Matteo','teo28273');
and this code works:
$db =& new mysqli('localhost','Matteo','teo28273');



Expected result:

The following code (and all mysqli functions) work properly:

$db = mysqli_connect('localhost','Matteo','teo28273'); or
$db = new mysqli('localhost','Matteo','teo28273');



Actual result:
--
Produces this error:
#Fatal error: Trying to clone an uncloneable object of class mysqli in
[***]\index.php on line 4


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


#35182 [Opn]: Successfully loaded, but cannot use Mysqli functions/class

2005-11-10 Thread webmaster at mif dot it
 ID:   35182
 User updated by:  webmaster at mif dot it
 Reported By:  webmaster at mif dot it
 Status:   Open
 Bug Type: MySQLi related
 Operating System: Win XP Pro
 PHP Version:  5.0.5
 New Comment:

Improving text


Previous Comments:


[2005-11-10 14:28:20] webmaster at mif dot it

Description:

Cannot use Mysqli functions, without using references.

Reproduce code:
---
This code:
$db = mysqli_connect('localhost','Matteo','teo28273');
and this doesn't works:
$db = new mysqli('localhost','Matteo','teo28273');

This code:
$db =& mysqli_connect('localhost','Matteo','teo28273');
and this code works:
$db =& new mysqli('localhost','Matteo','teo28273');



Expected result:

The following code (and all mysqli functions) work properly:

$db = mysqli_connect('localhost','Matteo','teo28273'); or
$db = new mysqli('localhost','Matteo','teo28273');



Actual result:
--
Produces this error:
#Fatal error: Trying to clone an uncloneable object of class mysqli in
[***]\index.php on line 4






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


#35182 [Opn]: Successfully loaded, but cannot use Mysqli functions/class

2005-11-10 Thread webmaster at mif dot it
 ID:   35182
 User updated by:  webmaster at mif dot it
 Reported By:  webmaster at mif dot it
 Status:   Open
 Bug Type: MySQLi related
 Operating System: Win XP Pro
 PHP Version:  5.0.5
 New Comment:

Editing


Previous Comments:


[2005-11-10 14:31:10] webmaster at mif dot it

Improving text



[2005-11-10 14:28:20] webmaster at mif dot it

Description:

Cannot use Mysqli functions, without using references.

Reproduce code:
---
This code:
$db = mysqli_connect('localhost','Matteo','teo28273');
and this doesn't works:
$db = new mysqli('localhost','Matteo','teo28273');

This code:
$db =& mysqli_connect('localhost','Matteo','teo28273');
and this code works:
$db =& new mysqli('localhost','Matteo','teo28273');



Expected result:

The following code (and all mysqli functions) work properly:

$db = mysqli_connect('localhost','Matteo','teo28273'); or
$db = new mysqli('localhost','Matteo','teo28273');



Actual result:
--
Produces this error:
#Fatal error: Trying to clone an uncloneable object of class mysqli in
[***]\index.php on line 4






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


#35182 [Opn->Bgs]: Successfully loaded, but cannot use Mysqli functions/class

2005-11-10 Thread johannes
 ID:   35182
 Updated by:   [EMAIL PROTECTED]
 Reported By:  webmaster at mif dot it
-Status:   Open
+Status:   Bogus
 Bug Type: MySQLi related
 Operating System: Win XP Pro
 PHP Version:  5.0.5
 New Comment:

You need to disable zendengine1 compatibility mode in your 
php.ini for using PHP 5 OO stuff. 


Previous Comments:


[2005-11-10 14:31:47] webmaster at mif dot it

Editing



[2005-11-10 14:31:10] webmaster at mif dot it

Improving text



[2005-11-10 14:28:20] webmaster at mif dot it

Description:

Cannot use Mysqli functions, without using references.

Reproduce code:
---
This code:
$db = mysqli_connect('localhost','Matteo','teo28273');
and this doesn't works:
$db = new mysqli('localhost','Matteo','teo28273');

This code:
$db =& mysqli_connect('localhost','Matteo','teo28273');
and this code works:
$db =& new mysqli('localhost','Matteo','teo28273');



Expected result:

The following code (and all mysqli functions) work properly:

$db = mysqli_connect('localhost','Matteo','teo28273'); or
$db = new mysqli('localhost','Matteo','teo28273');



Actual result:
--
Produces this error:
#Fatal error: Trying to clone an uncloneable object of class mysqli in
[***]\index.php on line 4






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


#35182 [Bgs]: Successfully loaded, but cannot use Mysqli functions/class

2005-11-10 Thread webmaster at mif dot it
 ID:   35182
 User updated by:  webmaster at mif dot it
 Reported By:  webmaster at mif dot it
 Status:   Bogus
 Bug Type: MySQLi related
 Operating System: Win XP Pro
 PHP Version:  5.0.5
 New Comment:

Thx, now it works properly, but some apps r really slow.


Previous Comments:


[2005-11-10 14:35:43] [EMAIL PROTECTED]

You need to disable zendengine1 compatibility mode in your 
php.ini for using PHP 5 OO stuff. 



[2005-11-10 14:31:47] webmaster at mif dot it

Editing



[2005-11-10 14:31:10] webmaster at mif dot it

Improving text



[2005-11-10 14:28:20] webmaster at mif dot it

Description:

Cannot use Mysqli functions, without using references.

Reproduce code:
---
This code:
$db = mysqli_connect('localhost','Matteo','teo28273');
and this doesn't works:
$db = new mysqli('localhost','Matteo','teo28273');

This code:
$db =& mysqli_connect('localhost','Matteo','teo28273');
and this code works:
$db =& new mysqli('localhost','Matteo','teo28273');



Expected result:

The following code (and all mysqli functions) work properly:

$db = mysqli_connect('localhost','Matteo','teo28273'); or
$db = new mysqli('localhost','Matteo','teo28273');



Actual result:
--
Produces this error:
#Fatal error: Trying to clone an uncloneable object of class mysqli in
[***]\index.php on line 4






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


#28038 [Com]: Sent incorrect RCPT TO commands to SMTP server

2005-11-10 Thread Ruben at e-builds dot com
 ID:   28038
 Comment by:   Ruben at e-builds dot com
 Reported By:  jordi at jcanals dot net
 Status:   Open
 Bug Type: Mail related
 Operating System: win32
 PHP Version:  5CVS, 4CVS (2005-08-08)
 New Comment:

The sames happens when using mail() with the 'From' part of the extra
headers.

php uses this Header From part (and others for RPath etc..) for the
"MAIL FROM" address in the SMTP protocol, at least if you didn't
specify the sendmail_from setting in php.ini.
But for one reason or another, php (I thínk it's php) wraps this part
in "<" and ">" again!

The workaround is not to use the special format -User <[EMAIL PROTECTED]>-,
but just the e-mail address "[EMAIL PROTECTED]".  Of course then php
scripters who like a professional approach and want to use this special
format, ..well..they can't, at least not per php script.


I use a Domino SMTP server on Win32.
P.S. I saw several bugs of the same kind allover.  Some are even
wrongly closed, I presume.


Previous Comments:


[2005-11-02 00:05:27] php-louis at steelbytes dot com

can we at least just implement stripping of leading and trailing white
space on what is extracted from the headers? (as that'll fix 35013).



[2005-11-01 11:37:04] [EMAIL PROTECTED]

See also bug #35013, one more way how headers are parsed wrong.



[2005-11-01 11:36:36] [EMAIL PROTECTED]

See also bug #32600 (rpath set wrong too)



[2005-01-25 00:26:34] [EMAIL PROTECTED]

The above patch is wrong. Only acceptable form for RCPT TO:
is:

RCPT TO:<[EMAIL PROTECTED]> 

Notice the brackets. Do not confuse yourself with RFC2822..
It does not obsolete 2821 as it talks about different thing.

So the fix is to drop the outside brackets stuff out of the addresses.




[2004-08-06 01:59:45] papercrane at reversefold dot com

Here's a possible patch for it. It's pretty simplistic, bit it should
work:

http://www.reversefold.com/sendmail.c.patch

Full file:

http://www.reversefold.com/sendmail.c

NOTE: I haven't actually *tested* this, it may not even compile. If it
doesn't, please send me a note and I'll try to fix it.



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/28038

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


#35183 [NEW]: write into mysql with utf8 not

2005-11-10 Thread lzx21cn at 21cn dot com
From: lzx21cn at 21cn dot com
Operating system: debian testing accuracy
PHP version:  4.4.1
PHP Bug Type: MySQL related
Bug description:  write into mysql with utf8 not  

Description:

write in mysql by utf8
it is wrong!

Reproduce code:
---
1.modify php.ini
...
mbstring.internal_encoding = UTF-8
mbstring.http_output = UTF-8
mbstring.detect_order = UTF-8

2. php file (utf8)
$sql="insert into test1 values(2,'四大皆空');";
mysql_query($sql);

Expected result:

*record where id=1 is inputed in gnome-terminal

 command: mysql IN gnome-terminal (utf8) 

select * from test1;

id | name
1  | 皆大欢喜
2  | 四大皆空
--

Actual result:
--
 command: mysql IN gnome-terminal (utf8) 

select * from test1;

id | name
1  | 皆大欢喜
2  | (something character which I unknow)
--

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


#34542 [Com]: register_long_arrays causes $_SESSIONS vars to disappear

2005-11-10 Thread uap-php at cheeky dot org
 ID:   34542
 Comment by:   uap-php at cheeky dot org
 Reported By:  marcus dot uy at virtualthinking dot com
 Status:   Feedback
 Bug Type: Session related
 Operating System: WinXP Pro
 PHP Version:  5.1.0RC4
 New Comment:

Hello,

Having similar problems on 5.0.5.  Basically all I can say is, if you
have register_long_arrays=Off in your ini file, $_SESSION stuff does
work, apart from when you iterate over it.  Run the code below, with
register_long_arrays=On and then with it off.  The final result will be
different.  It seems that if you iterate over $_SESSION, the
session_save handler does not get called and the session data is not
saved.

Hope this sheds some light on the problem,


$value){
$_SESSION[$key]='';
}
$step='empty session "search_test"';
$refresh='';
break;
case 1:
$step='nothing set in this step';
$refresh='';
break;
default:
$_SESSION['search_test'] = 'Hello!';
$step='set session "search_test" to "Hello"';
$refresh='';
}

?>

Session Data:';
print_r($_SESSION);
echo '';

?>



Previous Comments:


[2005-11-09 23:43:51] mail at lenzw dot de

see Bug #33811 for a reproduction code.



[2005-11-03 22:10:18] [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-11-03 16:47:25] marcus dot uy at virtualthinking dot com

Hi, I think somebody else has a related problem with a workable test
case.



[2005-11-03 09:36:44] marcus at synchromedia dot co dot uk

I think I'm seeing this same bug in 5.1.0RC4. I'm not 
getting exactly the same symptom, but it's close. I'm 
finding that session files are created no problem, but when 
I change values in $_SESSION, the changes are not saved, 
even if I use session_write_close(). I've set up a small 
test case that is storing and changing exactly what I'm 
doing in my project and it doesn't happen, so I don't think 
it's a problem with the contents of the session. I also 
wrote a test that stuffed 5000 strings into $_SESSION and 
that worked ok too.
Like the original bug report, it all works fine if I leave 
register_long_arrays turned on, even though I'm not using 
them anywhere in my code, or in libraries that I'm using.
What I would like to do is do a trace with xdebug and look 
at everything that involves sessions, but I can't at present 
because xdebug-cvs won't run under 5.1.0RC4.



[2005-09-19 13:47:45] [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.





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/34542

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


#35184 [NEW]: undefined function parse-error in if-clause

2005-11-10 Thread mg at memedia dot de
From: mg at memedia dot de
Operating system: Various
PHP version:  5.0.5
PHP Bug Type: Scripting Engine problem
Bug description:  undefined function parse-error in if-clause

Description:

This problem only occurs sometimes. I only had it for 5-8 times, but it
really drives me crazy for now. I can't explain myself to be such a bad
programmer, so it must be a bug. 


It occurs sometimes in if clauses like:

if (isset($a) || isset($b)) {
// do something
}

..and PHP returns 
"Fatal error: Call to undefined function  () in /index.php on line XX"


If the if-clause was "((isset($a)) || (isset($b)))" it helped to remove
the additional parenthesis, and do "(isset($a) || isset($b))2 instead.
Also the error was eliminated in some cases by adding another side to the
expressions, like "((isset($a)==true) || (isset($b)==false))".

But for now I'm really fed up with this:

$a=isset($_GET['action']);
$b=$a && (strpos($_GET['action'], 'admin')===false);

if (($a) || ($b)) {
echo "if it works or not doesn't matter; the question is if it can be
parsed";
}

I tried everything but I can't get that expression to work. In antoher
case i really wrote TWO if-clauses with only one statement that called one
and the same function. Working an above code also revaled that $b becomes
unexptected, when writing:

if ($a || $b) {
echo "if it works or not doesn't matter; the question is if it can be
parsed";
}
Parse error: parse error, unexpected T_VARIABLE in /index.php on line 353


Anyway, that error occurs only in some bunch of code and cannot really be
reproduced with a single file containing above code-snippets.

I appreciate appropiate workarounds for that problem ;)


PHP Version doesn't matter. I had the problem with PHP 4.x and still have
it with 5.04 and 5.1RC3.



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


#35183 [Opn->Fbk]: write into mysql with utf8 not

2005-11-10 Thread tony2001
 ID:   35183
 Updated by:   [EMAIL PROTECTED]
 Reported By:  lzx21cn at 21cn dot com
-Status:   Open
+Status:   Feedback
 Bug Type: MySQL related
 Operating System: debian testing accuracy
 PHP Version:  4.4.1
 New Comment:

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.




Previous Comments:


[2005-11-10 16:36:28] lzx21cn at 21cn dot com

Description:

write in mysql by utf8
it is wrong!

Reproduce code:
---
1.modify php.ini
...
mbstring.internal_encoding = UTF-8
mbstring.http_output = UTF-8
mbstring.detect_order = UTF-8

2. php file (utf8)
$sql="insert into test1 values(2,'四大皆空');";
mysql_query($sql);

Expected result:

*record where id=1 is inputed in gnome-terminal

 command: mysql IN gnome-terminal (utf8) 

select * from test1;

id | name
1  | 皆大欢喜
2  | 四大皆空
--

Actual result:
--
 command: mysql IN gnome-terminal (utf8) 

select * from test1;

id | name
1  | 皆大欢喜
2  | (something character which I unknow)
--





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


#35140 [Opn->Fbk]: Segmentation fault in shutdown_memory_manager

2005-11-10 Thread tony2001
 ID:   35140
 Updated by:   [EMAIL PROTECTED]
 Reported By:  jfbustarret at tf1 dot fr
-Status:   Open
+Status:   Feedback
 Bug Type: Scripting Engine problem
 Operating System: Linux
 PHP Version:  5CVS-2005-11-10 (snap)
 New Comment:

Are you able to reproduce it with PHP CLI?
Why are you using those CFLAGS? 
Do you really need both ext/mysql && ext/oci8? If not, please remove at
least one of them.
Do you use the new OCI8 (from PECL) or the old one?


Previous Comments:


[2005-11-10 13:58:21] jfbustarret at tf1 dot fr

With :
'./configure' '--with-apxs2=/usr/sbin/apxs2'
'--with-config-file-path=/etc' '--with-oci8=/soft/ora920'
'--prefix=/soft/php-5-200511100730-20051110-debug'
'--exec-prefix=/soft/php-5-200511100730-20051110-debug'
'--without-pear' '--with-mysql=/usr'
'--with-mysql-sock=/tmp/mysql.sock' 'CFLAGS=-O2 -g'

I get this crash :
#0  0x4070f068 in zend_clear_exception ()
at /soft/sources/php/php5-200511100730/Zend/zend_exceptions.c:68
68  if (!EG(exception)) {
(gdb) bt
#0  0x4070f068 in zend_clear_exception ()
at /soft/sources/php/php5-200511100730/Zend/zend_exceptions.c:68
#1  0x4071050d in zif_exception_getLine ()
at /soft/sources/php/php5-200511100730/Zend/zend_exceptions.c:220
#2  0x4083acf8 in ?? ()
[snip]
#16 0xbf9233e8 in ?? ()
#17 0x40710537 in zif_exception_getFile (ht=137277364,
return_value=0x2,
return_value_ptr=0x3a97, this_ptr=0x0,
return_value_used=137147524)
at /soft/sources/php/php5-200511100730/Zend/zend_exceptions.c:209
#18 0x40710537 in zif_exception_getFile (ht=0, return_value=0x82eafb4,
return_value_ptr=0x2, this_ptr=0x0, return_value_used=86073)
at /soft/sources/php/php5-200511100730/Zend/zend_exceptions.c:209
#19 0x406e2639 in zendparse () at zend_language_parser.c:4333
[snip]
(gdb) print executor_globals.exception
$1 = (zval *) 0x44238317
(gdb) print *executor_globals.exception
Cannot access memory at address 0x44238317

With more extensions, I have various crashes, like this one :
#0  0x406ed5fd in yy_push_state (new_state=1) at
zend_language_scanner.c:6029
#1  0x406edfe7 in lex_scan (zendlval=0xbf8163d4)
at zend_language_scanner.c:4418

I'll try the same with PHP-5.0.5.



[2005-11-10 10:52:37] [EMAIL PROTECTED]

Do you load those shared extensions in your php.ini?
Can you try without them? And what is the shortest possible configure
line you can reproduce this with?



[2005-11-10 10:31:56] jfbustarret at tf1 dot fr

With/without --enable-debug, php5-latests crashes in :

#0  0x4075c447 in _zend_hash_index_update_or_next_insert
(ht=0x4089cd40, h=0,
pData=0xbfee8100, nDataSize=12, pDest=0x0, flag=Variable "flag" is
not available.
)
at /soft/sources/php/php5-200511100730/Zend/zend_hash.c:354
#1  0x4075dc42 in zend_list_insert (ptr=0x0, type=0)
at /soft/sources/php/php5-200511100730/Zend/zend_list.c:47
#2  0x4075dc67 in zend_register_resource (rsrc_result=0x0,
rsrc_pointer=0x830b10c, rsrc_type=2)
at /soft/sources/php/php5-200511100730/Zend/zend_list.c:99
#3  0x4072b228 in _php_stream_alloc (ops=0x0, abstract=0x0,
persistent_id=0x0,
mode=0x407cafb7 "rb", __php_stream_call_depth=5,
__zend_filename=0x40806e28
"/soft/sources/php/php5-200511100730/main/streams/plain_wrapper.c",
__zend_lineno=205,
__zend_orig_filename=0x408048d4
"/soft/sources/php/php5-200511100730/main/main.c",
__zend_orig_lineno=855)
at /soft/sources/php/php5-200511100730/main/streams/streams.c:263
#4  0x4072e9c3 in _php_stream_fopen_from_fd (fd=27, mode=0x407cafb7
"rb",
persistent_id=0x0, __php_stream_call_depth=4,
__zend_filename=0x40806e28
"/soft/sources/php/php5-200511100730/main/streams/plain_wrapper.c",
__zend_lineno=882,
__zend_orig_filename=0x408048d4
"/soft/sources/php/php5-200511100730/main/main.c",
__zend_orig_lineno=855)
at
/soft/sources/php/php5-200511100730/main/streams/plain_wrapper.c:205
#5  0x4072eb40 in _php_stream_fopen (
filename=0x83170a8 "/data/www/www/htdocs/src/affichePage.php",
mode=0x407cafb7 "rb", opened_path=0xbfee95f8, options=133,
__php_stream_call_depth=3,
__zend_filename=0x40806e28
"/soft/sources/php/php5-200511100730/main/streams/plain_wrapper.c",
__zend_lineno=1233,
__zend_orig_filename=0x408048d4
"/soft/sources/php/php5-200511100730/main/ma---Type  to
continue, or q  to quit---
in.c", __zend_orig_lineno=855)
at
/soft/sources/php/php5-200511100730/main/streams/plain_wrapper.c:882
#6  0x4072ed65 in _php_stream_fopen_with_path (
filename=0x83170a8 "/data/www/www/ht

#35184 [Opn->Fbk]: undefined function parse-error in if-clause

2005-11-10 Thread tony2001
 ID:   35184
 Updated by:   [EMAIL PROTECTED]
 Reported By:  mg at memedia dot de
-Status:   Open
+Status:   Feedback
 Bug Type: Scripting Engine problem
 Operating System: Various
 PHP Version:  5.0.5
 New Comment:

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.




Previous Comments:


[2005-11-10 17:22:12] mg at memedia dot de

Description:

This problem only occurs sometimes. I only had it for 5-8 times, but it
really drives me crazy for now. I can't explain myself to be such a bad
programmer, so it must be a bug. 


It occurs sometimes in if clauses like:

if (isset($a) || isset($b)) {
// do something
}

..and PHP returns 
"Fatal error: Call to undefined function  () in /index.php on line XX"


If the if-clause was "((isset($a)) || (isset($b)))" it helped to remove
the additional parenthesis, and do "(isset($a) || isset($b))2 instead.
Also the error was eliminated in some cases by adding another side to
the expressions, like "((isset($a)==true) || (isset($b)==false))".

But for now I'm really fed up with this:

$a=isset($_GET['action']);
$b=$a && (strpos($_GET['action'], 'admin')===false);

if (($a) || ($b)) {
echo "if it works or not doesn't matter; the question is if it can be
parsed";
}

I tried everything but I can't get that expression to work. In antoher
case i really wrote TWO if-clauses with only one statement that called
one and the same function. Working an above code also revaled that $b
becomes unexptected, when writing:

if ($a || $b) {
echo "if it works or not doesn't matter; the question is if it can be
parsed";
}
Parse error: parse error, unexpected T_VARIABLE in /index.php on line
353


Anyway, that error occurs only in some bunch of code and cannot really
be reproduced with a single file containing above code-snippets.

I appreciate appropiate workarounds for that problem ;)


PHP Version doesn't matter. I had the problem with PHP 4.x and still
have it with 5.04 and 5.1RC3.







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


#35153 [Bgs->Opn]: php_bz2.dll STILL Missing from Windows installation on 5.0.5

2005-11-10 Thread php_bug at cerdmann dot com
 ID:   35153
 User updated by:  php_bug at cerdmann dot com
 Reported By:  php_bug at cerdmann dot com
-Status:   Bogus
+Status:   Open
 Bug Type: Bzip2 Related
 Operating System: Windows XP
 PHP Version:  5.0.5
 New Comment:

> 5.0.x is no longer supported once 5.1 is out.
That´s right, but at the moment the 5.0.5 ist the latest stable
release. So it has to be corrected.


Previous Comments:


[2005-11-08 17:07:14] [EMAIL PROTECTED]

Yes, but the thing exists in 5.1.0. :)
FYI: 5.0.x is no longer supported once 5.1 is out.



[2005-11-08 14:55:47] php_bug at cerdmann dot com

Do not work. The version of the file in the zip is 5.1.0.0. Seems not
to work with 5.0.* branch.



[2005-11-08 13:42:55] [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-11-08 13:16:39] php_bug at cerdmann dot com

Description:

As seen in the summary... the file is still missing, also in Snapshots.
Where can i get from?






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


#34729 [Fbk->Opn]: SoapClient<->SoapServer crashes under apache with 5.10RC2

2005-11-10 Thread matthew_peters at uk dot ibm dot com
 ID:   34729
 User updated by:  matthew_peters at uk dot ibm dot com
 Reported By:  matthew_peters at uk dot ibm dot com
-Status:   Feedback
+Status:   Open
 Bug Type: SOAP related
 Operating System: WinXP
 PHP Version:  5CVS-2005-10-04 (snap)
 Assigned To:  dmitry
 New Comment:

Perhaps I have a bad configuration as you say but I don't know what
sort of misconfiguration could cause a crash like this.

One possibility: perhaps you did not see the problem because you are
running Apache 1.3 whereas I am running Apache 2 ... the threading is
quite different. 

I agree the stack trace doesn't show SoapClient anywhere but using
SoapClient does provoke the problem. The problem appeared when I moved
from RC1 to RC2, so it is presumably some weakness in PHP RC2 and
beyond which SoapClient uncovers.


Previous Comments:


[2005-11-08 14:54:51] [EMAIL PROTECTED]

I just checked RC4 from http://downloads.php.net/ilia/ and it works
fine for me (Apache/1.3.28 (Win32) PHP/5.1.0RC4).

Probalby you have this bug because of missconfiguration.

The debug backtrace is not related to ext/soap.



[2005-11-01 14:52:28] matthew_peters at uk dot ibm dot com

For info, still fails in the same way with RC4. I haven't rebuilt with
debug to check that the call stack is the same, though.



[2005-10-21 19:12:35] matthew_peters at uk dot ibm dot com

Juts tried with RC3 and the problem is still there. I was able to build
a debug build of the apache sapi and the soap extension with no problem
though.

Windows pops up a dialog box to take you to the debugger. It claims
there has been an access violation.

The call stack is 
NTDLL! 77f584ae()
_emalloc(unsigned int 10, char * 0x013656e8 `string', unsigned int 240,
char * 0x, unsigned int 0) line 182 + 63 bytes
_estrdup(const char * 0x00784518, char * 0x013656e8 `string', unsigned
int 240, char * 0x, unsigned int 0) line 403 + 25 bytes
sapi_get_default_content_type(void * * * 0x00b7b7a0) line 240 + 29
bytes
php_apache_request_ctor(request_rec * 0x005e2818, php_struct *
0x005e4060, void * * * 0x00b7b7a0) line 419 + 12 bytes
php_handler(request_rec * 0x005e2818) line 531 + 17 bytes
LIBHTTPD! 6ff0155f()

It breaks quite consistently at this point. 

I stepped through under the debugger and the problem goes away - don't
they always.

sapi_get_default_context_type looks a pretty harmless piece of code
that is just trying to get the default context type, and ultimately
trying to do an estrdup of "test/html". I don't know why that should
fail. 

I don't know why the SOAP client should provoke this failure  in the
apache sapi. Neither do I know much about how the apache sapi is
supposed to work so although I would like to help debug this problem I
could do with some advice.



[2005-10-21 17:35:20] [EMAIL PROTECTED]

Use the rc3 build available from here:
http://downloads.php.net/ilia/



[2005-10-17 12:55:33] matthew_peters at uk dot ibm dot com

As I said in the last comment, I would be happy to investigate if I
could only get a debug build of RC2 that includes the soap extension.
When I try to build I get close to 20 link errors. 
php_http.obj : error LNK2001: unresolved external symbol
_executor_globals_id
soap.obj : error LNK2001: unresolved external symbol
_executor_globals_id
php_encoding.obj : error LNK2001: unresolved external symbol
_xmlStringTextNoenc

php_http.obj : error LNK2001: unresolved external symbol
_zval_used_for_init
soap.obj : error LNK2001: unresolved external symbol
_zval_used_for_init
php_http.obj : error LNK2001: unresolved external symbol
_core_globals_id
php_xml.obj : error LNK2001: unresolved external symbol
_core_globals_id
soap.obj : error LNK2001: unresolved external symbol _core_globals_id
php_http.obj : error LNK2001: unresolved external symbol
_compiler_globals_id
soap.obj : error LNK2001: unresolved external symbol
_compiler_globals_id
php_http.obj : error LNK2001: unresolved external symbol
_file_globals_id
php_sdl.obj : error LNK2001: unresolved external symbol
_file_globals_id
php_schema.obj : error LNK2001: unresolved external symbol _xmlFree
php_sdl.obj : error LNK2001: unresolved external symbol _xmlFree
soap.obj : error LNK2001: unresolved external symbol _xmlFree
soap.obj : error LNK2001: unresolved external symbol _zend_error_cb
soap.obj : error LNK2001: unresolved external symbol _ps_globals_id
Debug_TS\php_soap.dll : fatal error LNK1120: 10 unresolved externals

This is from a config line:
cscript /nologo configure.js 
"--with-extra-includes=..\libiconv\include;..\libxml2\include;..\apache2\inclu
de"
"--with-extra-libs=..\libiconv\lib

#35153 [Opn->Bgs]: php_bz2.dll STILL Missing from Windows installation on 5.0.5

2005-11-10 Thread sniper
 ID:   35153
 Updated by:   [EMAIL PROTECTED]
 Reported By:  php_bug at cerdmann dot com
-Status:   Open
+Status:   Bogus
 Bug Type: Bzip2 Related
 Operating System: Windows XP
 PHP Version:  5.0.5
 New Comment:

No, we don't HAVE to do anything. Correct your attitude and start using
the working 5.1 once it's released.



Previous Comments:


[2005-11-10 17:34:36] php_bug at cerdmann dot com

> 5.0.x is no longer supported once 5.1 is out.
That´s right, but at the moment the 5.0.5 ist the latest stable
release. So it has to be corrected.



[2005-11-08 17:07:14] [EMAIL PROTECTED]

Yes, but the thing exists in 5.1.0. :)
FYI: 5.0.x is no longer supported once 5.1 is out.



[2005-11-08 14:55:47] php_bug at cerdmann dot com

Do not work. The version of the file in the zip is 5.1.0.0. Seems not
to work with 5.0.* branch.



[2005-11-08 13:42:55] [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-11-08 13:16:39] php_bug at cerdmann dot com

Description:

As seen in the summary... the file is still missing, also in Snapshots.
Where can i get from?






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


#32220 [Fbk->Opn]: [PATCH] thread_resources for thread not getting freed when apache kills thread

2005-11-10 Thread sniper
 ID:   32220
 Updated by:   [EMAIL PROTECTED]
 Reported By:  kameshj at fastmail dot fm
-Status:   Feedback
+Status:   Open
 Bug Type: Apache2 related
 Operating System: *
 PHP Version:  5CVS, 4CVS (2005-03-25)
 Assigned To:  dmitry


Previous Comments:


[2005-11-08 09:50:11] [EMAIL PROTECTED]

I am not able to reproduce this. Seems like a mess in report. Apache2
worker MPM doesn't support StartThreads and MaxThreads directives.



[2005-11-03 22:21:58] [EMAIL PROTECTED]

Dmitry, can you check this out?



[2005-03-25 02:05:13] [EMAIL PROTECTED]

Zeev, here's another thread issue, can you take a look in the patch?




[2005-03-25 02:04:47] [EMAIL PROTECTED]

Assuming this is not fixed in latest HEAD, PHP_5_0 or PHP_4_3 CVS
branches.




[2005-03-07 15:06:48] kameshj at fastmail dot fm

Description:

Run apache2 in a worker thread model with the following settings
StartThreads 3
MaxSpareThreads 4
MaxThreads 10
Loadtests on a very simple php scripts like the one that calls
phpinfo() at regular intervals of 5 minutes causes a memory leak(Not
really a leak but huge unused memory that gets freed at tsrm_shutdown)

This causes the memory consumed by the apache2 procsss to shoot up.

---Investigation
Apache2 to handle the concurrent requests increases the number of child
threads to max of MaxThreads when no more request to server it kills the
threads till the number of threads comes to MaxSpareThreads.

In the case of setting given above after the load test of 10
simultaneous requests,
Apache kills 6 threads (As MaxThreads-MaxSpareThreads = 10-4 = 6).
The thread_resources momory associated with these 6 threads still not
freed as soon as the corresponding thread is killed.
These kind of spurt loads at regular intervals causes lots of such
thread_resources memory to get accumulated not being used for any real
purpose.

Only when the sapi module comes down it calls tsrm_shutdown then these
thread_resources are getting freed.

Attaching the patch to fix the issue is available at
http://puggy.symonds.net/~kameshj/TSRM.c.patch

This patch has a few clean up to existing ts_free_thread.
This patch registers ts_free_thread as thread cleanup routine.

Reproduce code:
---
Run apache2 in a worker thread model with the following settings
StartThreads 3
MaxSpareThreads 4
MaxThreads 10

write a simple test.php

Run a load test with ab 
ab -n 40 -c 10
Wait for 5 minutes
ab -n 40 -c 10
Wait for 5 minutes
ab -n 40 -c 10
Wait for 5 minutes
ab -n 40 -c 10


Expected result:

In the case of setting given above after the load test of 10
simultaneous requests,
Apache kills 6 threads (As MaxThreads-MaxSpareThreads = 10-4 = 6).
The thread_resources momory associated with these 6 threads still not
freed as soon as the corresponding thread is killed.
These kind of spurt loads at regular intervals causes lots of such
thread_resources memory to get accumulated not being used for any real
purpose.

Only when the sapi module comes down it calls tsrm_shutdown then these
thread_resources are getting freed.


Actual result:
--
thread_resources of a thread that gets killed should get freed as soon
as it dies rather than waiting till the tsrm_shutdown





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


#32220 [Opn->Asn]: [PATCH] thread_resources for thread not getting freed when apache kills thread

2005-11-10 Thread sniper
 ID:   32220
 Updated by:   [EMAIL PROTECTED]
 Reported By:  kameshj at fastmail dot fm
-Status:   Open
+Status:   Assigned
 Bug Type: Apache2 related
 Operating System: *
 PHP Version:  5CVS, 4CVS (2005-03-25)
 Assigned To:  dmitry
 New Comment:

Yes, but did you check out the patch..?



Previous Comments:


[2005-11-08 09:50:11] [EMAIL PROTECTED]

I am not able to reproduce this. Seems like a mess in report. Apache2
worker MPM doesn't support StartThreads and MaxThreads directives.



[2005-11-03 22:21:58] [EMAIL PROTECTED]

Dmitry, can you check this out?



[2005-03-25 02:05:13] [EMAIL PROTECTED]

Zeev, here's another thread issue, can you take a look in the patch?




[2005-03-25 02:04:47] [EMAIL PROTECTED]

Assuming this is not fixed in latest HEAD, PHP_5_0 or PHP_4_3 CVS
branches.




[2005-03-07 15:06:48] kameshj at fastmail dot fm

Description:

Run apache2 in a worker thread model with the following settings
StartThreads 3
MaxSpareThreads 4
MaxThreads 10
Loadtests on a very simple php scripts like the one that calls
phpinfo() at regular intervals of 5 minutes causes a memory leak(Not
really a leak but huge unused memory that gets freed at tsrm_shutdown)

This causes the memory consumed by the apache2 procsss to shoot up.

---Investigation
Apache2 to handle the concurrent requests increases the number of child
threads to max of MaxThreads when no more request to server it kills the
threads till the number of threads comes to MaxSpareThreads.

In the case of setting given above after the load test of 10
simultaneous requests,
Apache kills 6 threads (As MaxThreads-MaxSpareThreads = 10-4 = 6).
The thread_resources momory associated with these 6 threads still not
freed as soon as the corresponding thread is killed.
These kind of spurt loads at regular intervals causes lots of such
thread_resources memory to get accumulated not being used for any real
purpose.

Only when the sapi module comes down it calls tsrm_shutdown then these
thread_resources are getting freed.

Attaching the patch to fix the issue is available at
http://puggy.symonds.net/~kameshj/TSRM.c.patch

This patch has a few clean up to existing ts_free_thread.
This patch registers ts_free_thread as thread cleanup routine.

Reproduce code:
---
Run apache2 in a worker thread model with the following settings
StartThreads 3
MaxSpareThreads 4
MaxThreads 10

write a simple test.php

Run a load test with ab 
ab -n 40 -c 10
Wait for 5 minutes
ab -n 40 -c 10
Wait for 5 minutes
ab -n 40 -c 10
Wait for 5 minutes
ab -n 40 -c 10


Expected result:

In the case of setting given above after the load test of 10
simultaneous requests,
Apache kills 6 threads (As MaxThreads-MaxSpareThreads = 10-4 = 6).
The thread_resources momory associated with these 6 threads still not
freed as soon as the corresponding thread is killed.
These kind of spurt loads at regular intervals causes lots of such
thread_resources memory to get accumulated not being used for any real
purpose.

Only when the sapi module comes down it calls tsrm_shutdown then these
thread_resources are getting freed.


Actual result:
--
thread_resources of a thread that gets killed should get freed as soon
as it dies rather than waiting till the tsrm_shutdown





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


#35185 [NEW]: libs/libphp4.so: No such file or directory (When Compiling with GD Support)

2005-11-10 Thread lcalvert at mn dot rr dot com
From: lcalvert at mn dot rr dot com
Operating system: FreeBSD 4.5
PHP version:  4.4.1
PHP Bug Type: Compile Failure
Bug description:  libs/libphp4.so: No such file or directory (When Compiling 
with GD Support)

Description:

Wehn compiling PHP 4.4.1 with GD Support during make it does not create a
libs/libphp4.so nor one in .libs. However when created without GD Support
all fuctions properly.

Reproduce code:
---
make install

Expected result:

darkunderdog# make install
Installing PHP SAPI module:   apache
cp libs/libphp4.so /usr/local/libexec/apache/libphp4.so
chmod 755 /usr/local/libexec/apache/libphp4.so
[activating module `php4' in /usr/local/etc/apache/httpd.conf]
Installing build environment: /usr/local/lib/php/build/
Installing header files:  /usr/local/include/php/
Installing helper programs:   /usr/local/bin/
  program: phpize
  program: php-config
Installing man pages: /usr/local/man/man1/
  page: phpize.1
  page: php-config.1


Actual result:
--
darkunderdog# make install
make: don't know how to make instal. Stop
darkunderdog# make install
Installing PHP SAPI module:   apache
cp libs/libphp4.so /usr/local/libexec/apache/libphp4.so
cp: libs/libphp4.so: No such file or directory
apxs:Break: Command failed with rc=1
*** Error code 1

Stop in /usr/home/underdog/phpinstall/php-4.4.1.

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


#35096 [Com]: using mod_rewrite with apache2 crashes

2005-11-10 Thread asmodai at in-nomine dot org
 ID:   35096
 Comment by:   asmodai at in-nomine dot org
 Reported By:  rob at burningsoda dot com
 Status:   Feedback
 Bug Type: Apache2 related
 Operating System: *
 PHP Version:  5CVS, 4CVS (2005-11-04) (snap)
 New Comment:

I upgraded from FreeBSD 5.4, Apache 2.0.54 with mod_php 4.3.x to 6.0,
Apache 2.0.55 and mod_php 4.4.1.

After this both Gallery 2 and Drupal 4.6.3 are having difficulties.

At first I thought it might be threading and recompiled apache and
mod_php to be prefork.  Same issue.

What I see is that my site works normally until I try to log in with
drupal, at which point I get the famous 'empty page' and I noticed in
my log file that:

[Thu Nov 10 17:58:47 2005] [notice] child pid 73748 exit signal
Segmentation fault (11)

Like other people I have been using the same configuration files and
have not changed anything during the upgrades.

Yes, I have mod_rewrite enabled.

The ktrace output I got from one of the dying children wasn't helpful,
so I am now trying strace to see if I can get some more information.


Previous Comments:


[2005-11-09 17:23:49] free4cd at yahoo dot de

This is the only debug output I get:

/root/php-4.4.1/Zend/zend_hash.c(275) :  Freeing 0x0868C2A4 (40 bytes),
script=/
srv/www/htdocs/index.php
Last leak repeated 45 times
/root/php-4.4.1/Zend/zend_execute.c(512) :  Freeing 0x0855441C (12
bytes), scrip
t=/srv/www/htdocs/index.php
/root/php-4.4.1/Zend/zend_opcode.c(295) :  Freeing 0x08535764 (30300
bytes), scr
ipt=/srv/www/htdocs/index.php
/root/php-4.4.1/Zend/zend_operators.c(1068) :  Freeing 0x08554304 (2
bytes), scr
ipt=/srv/www/htdocs/index.php
/root/php-4.4.1/Zend/zend_compile.c(875) :  Freeing 0x085542CC (7
bytes), script
=/srv/www/htdocs/index.php
/root/php-4.4.1/Zend/zend_variables.c(111) : Actual location (location
was relay
ed)
Last leak repeated 13 times
Zend/zend_language_scanner.c(4526) :  Freeing 0x08554294 (7 bytes),
script=/srv/www/htdocs/index.php
Last leak repeated 52 times
Zend/zend_language_scanner.c(4744) :  Freeing 0x0855425C (7 bytes),
script=/srv/
www/htdocs/index.php
Last leak repeated 64 times
Zend/zend_language_scanner.c(4518) :  Freeing 0x08554224 (4 bytes),
script=/srv/
www/htdocs/index.php
Last leak repeated 118 times
Zend/zend_language_scanner.c(4653) :  Freeing 0x085541EC (3 bytes),
script=/srv/
www/htdocs/index.php
Last leak repeated 19 times
/root/php-4.4.1/Zend/zend_opcode.c(230) :  Freeing 0x0855416C (24
bytes), script
=/srv/www/htdocs/index.php
Zend/zend_language_scanner.c(3945) :  Freeing 0x085540C4 (5 bytes),
script=/srv/
www/htdocs/index.php
Last leak repeated 21 times
/root/php-4.4.1/Zend/zend_execute.c(1080) :  Freeing 0x08554084 (12
bytes), scri
pt=/srv/www/htdocs/index.php
Zend/zend_language_scanner.c(4433) :  Freeing 0x086F4704 (28 bytes),
script=/srv
/www/htdocs/index.php
Last leak repeated 7 times
/root/php-4.4.1/Zend/zend_compile.c(1790) :  Freeing 0x08711ECC (13
bytes), scri
pt=/srv/www/htdocs/index.php
/root/php-4.4.1/Zend/zend_variables.c(111) : Actual location (location
was relay
ed)
Last leak repeated 1 time
/root/php-4.4.1/Zend/zend_compile.c(1774) :  Freeing 0x08711DDC (13
bytes), scri
pt=/srv/www/htdocs/index.php
/root/php-4.4.1/Zend/zend_variables.c(111) : Actual location (location
was relay
ed)
Last leak repeated 1 time
Zend/zend_language_scanner.c(4866) :  Freeing 0x0856D684 (2 bytes),
script=/srv/
www/htdocs/index.php
Last leak repeated 3 times
Zend/zend_language_scanner.c(4534) :  Freeing 0x0868D16C (3 bytes),
script=/srv/
www/htdocs/index.php
Last leak repeated 1 time
/root/php-4.4.1/Zend/zend_opcode.c(65) :  Freeing 0x082CAE94 (4 bytes),
script=/
srv/www/htdocs/index.php
/root/php-4.4.1/Zend/zend_compile.c(137) :  Freeing 0x082CAC9C (26
bytes), scrip
t=/srv/www/htdocs/index.php
Zend/zend_language_scanner.c(3096) :  Freeing 0x0868CD2C (84 bytes),
script=/srv
/www/htdocs/index.php
/root/php-4.4.1/ext/mbstring/mbstring.c(1016) :  Freeing 0x0868CCF4 (8
bytes), s
cript=/srv/www/htdocs/index.php
/root/php-4.4.1/Zend/zend_alloc.c(219) : Actual location (location was
relayed)
/root/php-4.4.1/Zend/zend_hash.c(199) :  Freeing 0x0868CCA4 (32 bytes),
script=/
srv/www/htdocs/index.php
Last leak repeated 8 times
/root/php-4.4.1/main/main.c(1520) :  Freeing 0x0868CB1C (44 bytes),
script=/srv/
www/htdocs/index.php
/root/php-4.4.1/Zend/zend_API.c(563) : Actual location (location was
relayed)
/root/php-4.4.1/main/main.c(1519) :  Freeing 0x0856B794 (12 bytes),
script=/srv/
www/htdocs/index.php
/root/php-4.4.1/main/main.c(1502) :  Freeing 0x086964EC (44 bytes),
script=/srv/
www/htdocs/index.php
/root/php-4.4.1/Zend/zend_API.c(563) : Actual location (location was
relayed)
/root/php-4.4.1/main/main.c(1501) :  Freeing 0x086964AC (12 bytes),
script=/srv/
www/htdocs/index.php
/root/php-4.4.1/main/php_variables.c(190) :  Freeing 0x086AFA84 (12
bytes), scri
pt=/srv/www/htdocs/index.php
Last leak repeated 28 times
/root/p

#35185 [Opn->Bgs]: libs/libphp4.so: No such file or directory (When Compiling with GD Support)

2005-11-10 Thread sniper
 ID:   35185
 Updated by:   [EMAIL PROTECTED]
 Reported By:  lcalvert at mn dot rr dot com
-Status:   Open
+Status:   Bogus
 Bug Type: Compile Failure
 Operating System: FreeBSD 4.5
 PHP Version:  4.4.1
 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-11-10 21:13:05] lcalvert at mn dot rr dot com

Description:

Wehn compiling PHP 4.4.1 with GD Support during make it does not create
a libs/libphp4.so nor one in .libs. However when created without GD
Support all fuctions properly.

Reproduce code:
---
make install

Expected result:

darkunderdog# make install
Installing PHP SAPI module:   apache
cp libs/libphp4.so /usr/local/libexec/apache/libphp4.so
chmod 755 /usr/local/libexec/apache/libphp4.so
[activating module `php4' in /usr/local/etc/apache/httpd.conf]
Installing build environment: /usr/local/lib/php/build/
Installing header files:  /usr/local/include/php/
Installing helper programs:   /usr/local/bin/
  program: phpize
  program: php-config
Installing man pages: /usr/local/man/man1/
  page: phpize.1
  page: php-config.1


Actual result:
--
darkunderdog# make install
make: don't know how to make instal. Stop
darkunderdog# make install
Installing PHP SAPI module:   apache
cp libs/libphp4.so /usr/local/libexec/apache/libphp4.so
cp: libs/libphp4.so: No such file or directory
apxs:Break: Command failed with rc=1
*** Error code 1

Stop in /usr/home/underdog/phpinstall/php-4.4.1.





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


#34729 [Opn->Fbk]: SoapClient<->SoapServer crashes under apache with 5.10RC2

2005-11-10 Thread sniper
 ID:   34729
 Updated by:   [EMAIL PROTECTED]
 Reported By:  matthew_peters at uk dot ibm dot com
-Status:   Open
+Status:   Feedback
 Bug Type: SOAP related
 Operating System: WinXP
 PHP Version:  5CVS-2005-10-04 (snap)
 Assigned To:  dmitry
 New Comment:

Can you reproduce this with Linux? And NOT using some threaded 
webserver since we don't really support that..



Previous Comments:


[2005-11-10 17:48:36] matthew_peters at uk dot ibm dot com

Perhaps I have a bad configuration as you say but I don't know what
sort of misconfiguration could cause a crash like this.

One possibility: perhaps you did not see the problem because you are
running Apache 1.3 whereas I am running Apache 2 ... the threading is
quite different. 

I agree the stack trace doesn't show SoapClient anywhere but using
SoapClient does provoke the problem. The problem appeared when I moved
from RC1 to RC2, so it is presumably some weakness in PHP RC2 and
beyond which SoapClient uncovers.



[2005-11-08 14:54:51] [EMAIL PROTECTED]

I just checked RC4 from http://downloads.php.net/ilia/ and it works
fine for me (Apache/1.3.28 (Win32) PHP/5.1.0RC4).

Probalby you have this bug because of missconfiguration.

The debug backtrace is not related to ext/soap.



[2005-11-01 14:52:28] matthew_peters at uk dot ibm dot com

For info, still fails in the same way with RC4. I haven't rebuilt with
debug to check that the call stack is the same, though.



[2005-10-21 19:12:35] matthew_peters at uk dot ibm dot com

Juts tried with RC3 and the problem is still there. I was able to build
a debug build of the apache sapi and the soap extension with no problem
though.

Windows pops up a dialog box to take you to the debugger. It claims
there has been an access violation.

The call stack is 
NTDLL! 77f584ae()
_emalloc(unsigned int 10, char * 0x013656e8 `string', unsigned int 240,
char * 0x, unsigned int 0) line 182 + 63 bytes
_estrdup(const char * 0x00784518, char * 0x013656e8 `string', unsigned
int 240, char * 0x, unsigned int 0) line 403 + 25 bytes
sapi_get_default_content_type(void * * * 0x00b7b7a0) line 240 + 29
bytes
php_apache_request_ctor(request_rec * 0x005e2818, php_struct *
0x005e4060, void * * * 0x00b7b7a0) line 419 + 12 bytes
php_handler(request_rec * 0x005e2818) line 531 + 17 bytes
LIBHTTPD! 6ff0155f()

It breaks quite consistently at this point. 

I stepped through under the debugger and the problem goes away - don't
they always.

sapi_get_default_context_type looks a pretty harmless piece of code
that is just trying to get the default context type, and ultimately
trying to do an estrdup of "test/html". I don't know why that should
fail. 

I don't know why the SOAP client should provoke this failure  in the
apache sapi. Neither do I know much about how the apache sapi is
supposed to work so although I would like to help debug this problem I
could do with some advice.



[2005-10-14 19:11:34] matthew_peters at uk dot ibm dot com

I just checked and still fails in the same way - that is it fails and
works alternately - with the latest from snaps, that is, a build dated
1014. Note I am using Windows, not Linux. I just also checked that it
does work perfectly with my php5-RC1. I would try to build a debug
build and look at the problem myself but my attempt to build with the
soap extension enabled failed at the link step...I am not exactly sure
what the right config options are. 

BTW we had a similar (but not identical) problem with the SDO extension
that turned out to be our code calling xmlCleanupParser and reinstalling
the default input handlers so they no longer went through PHP. That
would cause the failures on every call from the second onward though. 

The exact code I am using, cut and pasted, is:
the client:

 1,
"exceptions" => 0));
print($client->getQuote("ibm"));
?>

the server: 98.45);

function getQuote($symbol) {
global $quotes;
return $quotes[$symbol];
}

ini_set("soap.wsdl_cache_enabled", 0);

$server = new SoapServer("C:\Program Files\Apache
Group\Apache2\htdocs\stockquote.wsdl");
$server->addFunction("getQuote");
$server->handle();

?>

The wsdl is a bit larger and is taken from the article, unchanged
except for the 
 
at the bottom.



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/34729

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


#35186 [NEW]: getcwd() return "/" when using with mod_rewrite

2005-11-10 Thread samm at os2 dot kiev dot ua
From: samm at os2 dot kiev dot ua
Operating system: FreeBSD 6
PHP version:  4.4.1
PHP Bug Type: Apache2 related
Bug description:  getcwd() return "/" when using with mod_rewrite

Description:

When i use getcwd() function in my script which work with mod_rewrite i
got "/" instead of real path. Without mod_rewrite redirection all work
just fine. I check this with STABLE-200511101949 snapshot. With php 4.4.0
all work as expected.

Reproduce code:
---
To reproduce this bug do:
1) Enable mod_rewrite in apache2 config file
2) make .htaccess file with content like:
RewriteEngine on  
 
RewriteRule^test.html$ test.php [L]   
 
and place it in your virtual server root directory.
3) Create file "test.php" with content like 

and then point your browser to the "yoursever/test.html".
Then try yoursever/test.php

Expected result:

real path, same in 2 examples, e.g.
/usr/home/samm/htdocs
/usr/home/samm/htdocs

Actual result:
--
/
/usr/home/samm/htdocs

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


#35186 [Opn]: getcwd() return "/" when using with mod_rewrite

2005-11-10 Thread samm at os2 dot kiev dot ua
 ID:   35186
 User updated by:  samm at os2 dot kiev dot ua
 Reported By:  samm at os2 dot kiev dot ua
 Status:   Open
 Bug Type: Apache2 related
 Operating System: FreeBSD 6
 PHP Version:  4.4.1
 New Comment:

I forgot to say that i use php as  shared Apache 2.0 module with apache
2.0.54


Previous Comments:


[2005-11-10 22:46:47] samm at os2 dot kiev dot ua

Description:

When i use getcwd() function in my script which work with mod_rewrite i
got "/" instead of real path. Without mod_rewrite redirection all work
just fine. I check this with STABLE-200511101949 snapshot. With php
4.4.0 all work as expected.

Reproduce code:
---
To reproduce this bug do:
1) Enable mod_rewrite in apache2 config file
2) make .htaccess file with content like:
RewriteEngine on   

RewriteRule^test.html$ test.php [L]

and place it in your virtual server root directory.
3) Create file "test.php" with content like 

and then point your browser to the "yoursever/test.html".
Then try yoursever/test.php

Expected result:

real path, same in 2 examples, e.g.
/usr/home/samm/htdocs
/usr/home/samm/htdocs

Actual result:
--
/
/usr/home/samm/htdocs





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


#35186 [Opn->Fbk]: getcwd() return "/" when using with mod_rewrite

2005-11-10 Thread sniper
 ID:   35186
 Updated by:   [EMAIL PROTECTED]
 Reported By:  samm at os2 dot kiev dot ua
-Status:   Open
+Status:   Feedback
 Bug Type: Apache2 related
 Operating System: FreeBSD 6
 PHP Version:  4.4.1
 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

Works fine for me.


Previous Comments:


[2005-11-10 22:51:15] samm at os2 dot kiev dot ua

I forgot to say that i use php as  shared Apache 2.0 module with apache
2.0.54



[2005-11-10 22:46:47] samm at os2 dot kiev dot ua

Description:

When i use getcwd() function in my script which work with mod_rewrite i
got "/" instead of real path. Without mod_rewrite redirection all work
just fine. I check this with STABLE-200511101949 snapshot. With php
4.4.0 all work as expected.

Reproduce code:
---
To reproduce this bug do:
1) Enable mod_rewrite in apache2 config file
2) make .htaccess file with content like:
RewriteEngine on   

RewriteRule^test.html$ test.php [L]

and place it in your virtual server root directory.
3) Create file "test.php" with content like 

and then point your browser to the "yoursever/test.html".
Then try yoursever/test.php

Expected result:

real path, same in 2 examples, e.g.
/usr/home/samm/htdocs
/usr/home/samm/htdocs

Actual result:
--
/
/usr/home/samm/htdocs





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


#35186 [Fbk->Opn]: getcwd() return "/" when using with mod_rewrite

2005-11-10 Thread samm at os2 dot kiev dot ua
 ID:   35186
 User updated by:  samm at os2 dot kiev dot ua
 Reported By:  samm at os2 dot kiev dot ua
-Status:   Feedback
+Status:   Open
 Bug Type: Apache2 related
 Operating System: FreeBSD 6
 PHP Version:  4.4.1
 New Comment:

I check this with php5-200511102130 - the bug is still present.


Previous Comments:


[2005-11-10 22:53:44] [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

Works fine for me.



[2005-11-10 22:51:15] samm at os2 dot kiev dot ua

I forgot to say that i use php as  shared Apache 2.0 module with apache
2.0.54



[2005-11-10 22:46:47] samm at os2 dot kiev dot ua

Description:

When i use getcwd() function in my script which work with mod_rewrite i
got "/" instead of real path. Without mod_rewrite redirection all work
just fine. I check this with STABLE-200511101949 snapshot. With php
4.4.0 all work as expected.

Reproduce code:
---
To reproduce this bug do:
1) Enable mod_rewrite in apache2 config file
2) make .htaccess file with content like:
RewriteEngine on   

RewriteRule^test.html$ test.php [L]

and place it in your virtual server root directory.
3) Create file "test.php" with content like 

and then point your browser to the "yoursever/test.html".
Then try yoursever/test.php

Expected result:

real path, same in 2 examples, e.g.
/usr/home/samm/htdocs
/usr/home/samm/htdocs

Actual result:
--
/
/usr/home/samm/htdocs





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


#35186 [Opn->Fbk]: getcwd() return "/" when using with mod_rewrite

2005-11-10 Thread sniper
 ID:   35186
 Updated by:   [EMAIL PROTECTED]
 Reported By:  samm at os2 dot kiev dot ua
-Status:   Open
+Status:   Feedback
 Bug Type: Apache2 related
 Operating System: FreeBSD 6
-PHP Version:  4.4.1
+PHP Version:  5CVS, 4CVS (2005-11-11) (snap)
 New Comment:

What was the configure line you used? What MPM is Apache using?



Previous Comments:


[2005-11-10 23:24:54] samm at os2 dot kiev dot ua

I check this with php5-200511102130 - the bug is still present.



[2005-11-10 22:53:44] [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

Works fine for me.



[2005-11-10 22:51:15] samm at os2 dot kiev dot ua

I forgot to say that i use php as  shared Apache 2.0 module with apache
2.0.54



[2005-11-10 22:46:47] samm at os2 dot kiev dot ua

Description:

When i use getcwd() function in my script which work with mod_rewrite i
got "/" instead of real path. Without mod_rewrite redirection all work
just fine. I check this with STABLE-200511101949 snapshot. With php
4.4.0 all work as expected.

Reproduce code:
---
To reproduce this bug do:
1) Enable mod_rewrite in apache2 config file
2) make .htaccess file with content like:
RewriteEngine on   

RewriteRule^test.html$ test.php [L]

and place it in your virtual server root directory.
3) Create file "test.php" with content like 

and then point your browser to the "yoursever/test.html".
Then try yoursever/test.php

Expected result:

real path, same in 2 examples, e.g.
/usr/home/samm/htdocs
/usr/home/samm/htdocs

Actual result:
--
/
/usr/home/samm/htdocs





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


#35186 [Fbk->Opn]: getcwd() return "/" when using with mod_rewrite

2005-11-10 Thread samm at os2 dot kiev dot ua
 ID:   35186
 User updated by:  samm at os2 dot kiev dot ua
 Reported By:  samm at os2 dot kiev dot ua
-Status:   Feedback
+Status:   Open
 Bug Type: Apache2 related
 Operating System: FreeBSD 6
 PHP Version:  5CVS, 4CVS (2005-11-11) (snap)
 New Comment:

PHP:
./configure --with-apxs2=/usr/local/sbin/apxs

Apache: 
-D APACHE_MPM_DIR="server/mpm/prefork"


Previous Comments:


[2005-11-10 23:28:45] [EMAIL PROTECTED]

What was the configure line you used? What MPM is Apache using?




[2005-11-10 23:24:54] samm at os2 dot kiev dot ua

I check this with php5-200511102130 - the bug is still present.



[2005-11-10 22:53:44] [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

Works fine for me.



[2005-11-10 22:51:15] samm at os2 dot kiev dot ua

I forgot to say that i use php as  shared Apache 2.0 module with apache
2.0.54



[2005-11-10 22:46:47] samm at os2 dot kiev dot ua

Description:

When i use getcwd() function in my script which work with mod_rewrite i
got "/" instead of real path. Without mod_rewrite redirection all work
just fine. I check this with STABLE-200511101949 snapshot. With php
4.4.0 all work as expected.

Reproduce code:
---
To reproduce this bug do:
1) Enable mod_rewrite in apache2 config file
2) make .htaccess file with content like:
RewriteEngine on   

RewriteRule^test.html$ test.php [L]

and place it in your virtual server root directory.
3) Create file "test.php" with content like 

and then point your browser to the "yoursever/test.html".
Then try yoursever/test.php

Expected result:

real path, same in 2 examples, e.g.
/usr/home/samm/htdocs
/usr/home/samm/htdocs

Actual result:
--
/
/usr/home/samm/htdocs





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


#35186 [Opn]: getcwd() returns "/" when using with mod_rewrite

2005-11-10 Thread sniper
 ID:   35186
 Updated by:   [EMAIL PROTECTED]
 Reported By:  samm at os2 dot kiev dot ua
 Status:   Open
 Bug Type: Apache2 related
 Operating System: FreeBSD 6
 PHP Version:  5CVS, 4CVS (2005-11-11) (snap)
 New Comment:

This must be some FreeBSD-only issue since this really works fine
within Linux.


Previous Comments:


[2005-11-10 23:37:20] samm at os2 dot kiev dot ua

PHP:
./configure --with-apxs2=/usr/local/sbin/apxs

Apache: 
-D APACHE_MPM_DIR="server/mpm/prefork"



[2005-11-10 23:28:45] [EMAIL PROTECTED]

What was the configure line you used? What MPM is Apache using?




[2005-11-10 23:24:54] samm at os2 dot kiev dot ua

I check this with php5-200511102130 - the bug is still present.



[2005-11-10 22:53:44] [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

Works fine for me.



[2005-11-10 22:51:15] samm at os2 dot kiev dot ua

I forgot to say that i use php as  shared Apache 2.0 module with apache
2.0.54



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/35186

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


#35186 [Opn]: getcwd() returns "/" when using with mod_rewrite

2005-11-10 Thread samm at os2 dot kiev dot ua
 ID:   35186
 User updated by:  samm at os2 dot kiev dot ua
 Reported By:  samm at os2 dot kiev dot ua
 Status:   Open
 Bug Type: Apache2 related
 Operating System: FreeBSD 6
 PHP Version:  5CVS, 4CVS (2005-11-11) (snap)
 New Comment:

May be. Anyway 4.4.0 work correctly, so this was broken in 4.4.1. I
have no linux around, so currently i cant check this in linux. I found
this bug on my 5.4 FreeBSD box, so that is not FreeBSD 6.0 related. I
can make some tests if you need. I think that regression was on
4.4.0->4.4.1, may be this can help you.


Previous Comments:


[2005-11-10 23:45:36] [EMAIL PROTECTED]

This must be some FreeBSD-only issue since this really works fine
within Linux.



[2005-11-10 23:37:20] samm at os2 dot kiev dot ua

PHP:
./configure --with-apxs2=/usr/local/sbin/apxs

Apache: 
-D APACHE_MPM_DIR="server/mpm/prefork"



[2005-11-10 23:28:45] [EMAIL PROTECTED]

What was the configure line you used? What MPM is Apache using?




[2005-11-10 23:24:54] samm at os2 dot kiev dot ua

I check this with php5-200511102130 - the bug is still present.



[2005-11-10 22:53:44] [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

Works fine for me.



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/35186

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


#35186 [Opn]: getcwd() returns "/" when using with mod_rewrite

2005-11-10 Thread samm at os2 dot kiev dot ua
 ID:   35186
 User updated by:  samm at os2 dot kiev dot ua
 Reported By:  samm at os2 dot kiev dot ua
 Status:   Open
 Bug Type: Apache2 related
 Operating System: FreeBSD 6
 PHP Version:  5CVS, 4CVS (2005-11-11) (snap)
 New Comment:

I tried to copy files from directory sapi/apache2handler of the
php4.4.0 to the latest 4.4-stable and than i recompiled php. After this
all path`s are displayed correctly, so problem is in the apache2handler
changes. Tomorrow i`ll try to make more detailt experiments to find a
change, which cause a regression.


Previous Comments:


[2005-11-10 23:50:40] samm at os2 dot kiev dot ua

May be. Anyway 4.4.0 work correctly, so this was broken in 4.4.1. I
have no linux around, so currently i cant check this in linux. I found
this bug on my 5.4 FreeBSD box, so that is not FreeBSD 6.0 related. I
can make some tests if you need. I think that regression was on
4.4.0->4.4.1, may be this can help you.



[2005-11-10 23:45:36] [EMAIL PROTECTED]

This must be some FreeBSD-only issue since this really works fine
within Linux.



[2005-11-10 23:37:20] samm at os2 dot kiev dot ua

PHP:
./configure --with-apxs2=/usr/local/sbin/apxs

Apache: 
-D APACHE_MPM_DIR="server/mpm/prefork"



[2005-11-10 23:28:45] [EMAIL PROTECTED]

What was the configure line you used? What MPM is Apache using?




[2005-11-10 23:24:54] samm at os2 dot kiev dot ua

I check this with php5-200511102130 - the bug is still present.



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/35186

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


#35186 [Opn]: getcwd() returns "/" when using with mod_rewrite

2005-11-10 Thread sniper
 ID:   35186
 Updated by:   [EMAIL PROTECTED]
 Reported By:  samm at os2 dot kiev dot ua
 Status:   Open
 Bug Type: Apache2 related
 Operating System: FreeBSD 6
 PHP Version:  5CVS, 4CVS (2005-11-11) (snap)
 New Comment:

Ah, thank you! This will help us pinpoint the problem very easily now.
I'll check what we changed between 4.4.0 / 4.4.1.



Previous Comments:


[2005-11-11 00:09:41] samm at os2 dot kiev dot ua

I tried to copy files from directory sapi/apache2handler of the
php4.4.0 to the latest 4.4-stable and than i recompiled php. After this
all path`s are displayed correctly, so problem is in the apache2handler
changes. Tomorrow i`ll try to make more detailt experiments to find a
change, which cause a regression.



[2005-11-10 23:50:40] samm at os2 dot kiev dot ua

May be. Anyway 4.4.0 work correctly, so this was broken in 4.4.1. I
have no linux around, so currently i cant check this in linux. I found
this bug on my 5.4 FreeBSD box, so that is not FreeBSD 6.0 related. I
can make some tests if you need. I think that regression was on
4.4.0->4.4.1, may be this can help you.



[2005-11-10 23:45:36] [EMAIL PROTECTED]

This must be some FreeBSD-only issue since this really works fine
within Linux.



[2005-11-10 23:37:20] samm at os2 dot kiev dot ua

PHP:
./configure --with-apxs2=/usr/local/sbin/apxs

Apache: 
-D APACHE_MPM_DIR="server/mpm/prefork"



[2005-11-10 23:28:45] [EMAIL PROTECTED]

What was the configure line you used? What MPM is Apache using?




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/35186

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


#35186 [Opn]: getcwd() returns "/" when using with mod_rewrite

2005-11-10 Thread sniper
 ID:   35186
 Updated by:   [EMAIL PROTECTED]
 Reported By:  samm at os2 dot kiev dot ua
 Status:   Open
 Bug Type: Apache2 related
 Operating System: FreeBSD 6
 PHP Version:  5CVS, 4CVS (2005-11-11) (snap)
 New Comment:

The only file changed was sapi/apache2handler/sapi_apache2.c



Previous Comments:


[2005-11-11 00:27:40] [EMAIL PROTECTED]

Ah, thank you! This will help us pinpoint the problem very easily now.
I'll check what we changed between 4.4.0 / 4.4.1.




[2005-11-11 00:09:41] samm at os2 dot kiev dot ua

I tried to copy files from directory sapi/apache2handler of the
php4.4.0 to the latest 4.4-stable and than i recompiled php. After this
all path`s are displayed correctly, so problem is in the apache2handler
changes. Tomorrow i`ll try to make more detailt experiments to find a
change, which cause a regression.



[2005-11-10 23:50:40] samm at os2 dot kiev dot ua

May be. Anyway 4.4.0 work correctly, so this was broken in 4.4.1. I
have no linux around, so currently i cant check this in linux. I found
this bug on my 5.4 FreeBSD box, so that is not FreeBSD 6.0 related. I
can make some tests if you need. I think that regression was on
4.4.0->4.4.1, may be this can help you.



[2005-11-10 23:45:36] [EMAIL PROTECTED]

This must be some FreeBSD-only issue since this really works fine
within Linux.



[2005-11-10 23:37:20] samm at os2 dot kiev dot ua

PHP:
./configure --with-apxs2=/usr/local/sbin/apxs

Apache: 
-D APACHE_MPM_DIR="server/mpm/prefork"



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/35186

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


#35186 [Opn->Fbk]: getcwd() returns "/" when using with mod_rewrite

2005-11-10 Thread sniper
 ID:   35186
 Updated by:   [EMAIL PROTECTED]
 Reported By:  samm at os2 dot kiev dot ua
-Status:   Open
+Status:   Feedback
 Bug Type: Apache2 related
 Operating System: FreeBSD 6
 PHP Version:  5CVS, 4CVS (2005-11-11) (snap)
 New Comment:

How have you enabled PHP in your httpd.conf?
(what loadmodule/etc. lines you added)



Previous Comments:


[2005-11-11 00:32:19] [EMAIL PROTECTED]

The only file changed was sapi/apache2handler/sapi_apache2.c




[2005-11-11 00:27:40] [EMAIL PROTECTED]

Ah, thank you! This will help us pinpoint the problem very easily now.
I'll check what we changed between 4.4.0 / 4.4.1.




[2005-11-11 00:09:41] samm at os2 dot kiev dot ua

I tried to copy files from directory sapi/apache2handler of the
php4.4.0 to the latest 4.4-stable and than i recompiled php. After this
all path`s are displayed correctly, so problem is in the apache2handler
changes. Tomorrow i`ll try to make more detailt experiments to find a
change, which cause a regression.



[2005-11-10 23:50:40] samm at os2 dot kiev dot ua

May be. Anyway 4.4.0 work correctly, so this was broken in 4.4.1. I
have no linux around, so currently i cant check this in linux. I found
this bug on my 5.4 FreeBSD box, so that is not FreeBSD 6.0 related. I
can make some tests if you need. I think that regression was on
4.4.0->4.4.1, may be this can help you.



[2005-11-10 23:45:36] [EMAIL PROTECTED]

This must be some FreeBSD-only issue since this really works fine
within Linux.



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/35186

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



#35186 [Fbk]: getcwd() returns "/" when using with mod_rewrite

2005-11-10 Thread sniper
 ID:   35186
 Updated by:   [EMAIL PROTECTED]
 Reported By:  samm at os2 dot kiev dot ua
 Status:   Feedback
 Bug Type: Apache2 related
 Operating System: FreeBSD 6
 PHP Version:  5CVS, 4CVS (2005-11-11) (snap)
 New Comment:

And what is HAVE_BROKEN_GETCWD set to in the generated
main/php_config.h file?




Previous Comments:


[2005-11-11 00:35:26] [EMAIL PROTECTED]

How have you enabled PHP in your httpd.conf?
(what loadmodule/etc. lines you added)




[2005-11-11 00:32:19] [EMAIL PROTECTED]

The only file changed was sapi/apache2handler/sapi_apache2.c




[2005-11-11 00:27:40] [EMAIL PROTECTED]

Ah, thank you! This will help us pinpoint the problem very easily now.
I'll check what we changed between 4.4.0 / 4.4.1.




[2005-11-11 00:09:41] samm at os2 dot kiev dot ua

I tried to copy files from directory sapi/apache2handler of the
php4.4.0 to the latest 4.4-stable and than i recompiled php. After this
all path`s are displayed correctly, so problem is in the apache2handler
changes. Tomorrow i`ll try to make more detailt experiments to find a
change, which cause a regression.



[2005-11-10 23:50:40] samm at os2 dot kiev dot ua

May be. Anyway 4.4.0 work correctly, so this was broken in 4.4.1. I
have no linux around, so currently i cant check this in linux. I found
this bug on my 5.4 FreeBSD box, so that is not FreeBSD 6.0 related. I
can make some tests if you need. I think that regression was on
4.4.0->4.4.1, may be this can help you.



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/35186

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


#35187 [NEW]: mb_internal_encoding() problem

2005-11-10 Thread kamil at webjay dot pl
From: kamil at webjay dot pl
Operating system: Windows XP / FreeBSD 5.4
PHP version:  4.4.1
PHP Bug Type: Unknown/Other Function
Bug description:  mb_internal_encoding() problem

Description:

I was tested it at:
- Apache 1.3.34 & Win XP
- Apache 2.0.54 & FreeBSD 5.4

If mb_internal_encoding() not exist - php don't report any errors.

Reproduce code:
---


Expected result:

PHP Fatal error:  Call to undefined function: mb_internal_encoding() in
C:\SERVER\www\webjay.pl\index.php on line 3.

Actual result:
--
NULL

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


#35187 [Opn->Bgs]: mb_internal_encoding() problem

2005-11-10 Thread sniper
 ID:   35187
 Updated by:   [EMAIL PROTECTED]
 Reported By:  kamil at webjay dot pl
-Status:   Open
+Status:   Bogus
-Bug Type: Unknown/Other Function
+Bug Type: mbstring related
 Operating System: Windows XP / FreeBSD 5.4
 PHP Version:  4.4.1
 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-11-11 01:34:41] kamil at webjay dot pl

Description:

I was tested it at:
- Apache 1.3.34 & Win XP
- Apache 2.0.54 & FreeBSD 5.4

If mb_internal_encoding() not exist - php don't report any errors.

Reproduce code:
---


Expected result:

PHP Fatal error:  Call to undefined function: mb_internal_encoding() in
C:\SERVER\www\webjay.pl\index.php on line 3.

Actual result:
--
NULL





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


#35187 [Bgs]: mb_internal_encoding() problem

2005-11-10 Thread kamil at webjay dot pl
 ID:   35187
 User updated by:  kamil at webjay dot pl
 Reported By:  kamil at webjay dot pl
 Status:   Bogus
 Bug Type: mbstring related
 Operating System: Windows XP / FreeBSD 5.4
 PHP Version:  4.4.1
 New Comment:

can you read? php do not report any error about don't exist function...
i have to guess - i got or not mb extension? NO ERRORS REPORING!


Previous Comments:


[2005-11-11 01:46:24] [EMAIL PROTECTED]

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.





[2005-11-11 01:34:41] kamil at webjay dot pl

Description:

I was tested it at:
- Apache 1.3.34 & Win XP
- Apache 2.0.54 & FreeBSD 5.4

If mb_internal_encoding() not exist - php don't report any errors.

Reproduce code:
---


Expected result:

PHP Fatal error:  Call to undefined function: mb_internal_encoding() in
C:\SERVER\www\webjay.pl\index.php on line 3.

Actual result:
--
NULL





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


#35188 [NEW]: switch always picks case 0

2005-11-10 Thread daniel at assertio dot es
From: daniel at assertio dot es
Operating system: Win XP
PHP version:  5.0.5
PHP Bug Type: Scripting Engine problem
Bug description:  switch always picks case 0

Description:

If a switch case is 0 and the variable value evaluated in the switch is a
string, that case is picked.

Reproduce code:
---
$var = "hello";
switch($var){
case 0: 
echo "var is 0";
break;
default:
echo "default!";
}

Expected result:

default!

Actual result:
--
var is 0

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


#35188 [Opn->Bgs]: switch always picks case 0

2005-11-10 Thread sniper
 ID:   35188
 Updated by:   [EMAIL PROTECTED]
 Reported By:  daniel at assertio dot es
-Status:   Open
+Status:   Bogus
 Bug Type: Scripting Engine problem
 Operating System: Win XP
 PHP Version:  5.0.5
 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-11-11 02:47:38] daniel at assertio dot es

Description:

If a switch case is 0 and the variable value evaluated in the switch is
a string, that case is picked.

Reproduce code:
---
$var = "hello";
switch($var){
case 0: 
echo "var is 0";
break;
default:
echo "default!";
}

Expected result:

default!

Actual result:
--
var is 0





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


#35186 [Fbk->Opn]: getcwd() returns "/" when using with mod_rewrite

2005-11-10 Thread samm at os2 dot kiev dot ua
 ID:   35186
 User updated by:  samm at os2 dot kiev dot ua
 Reported By:  samm at os2 dot kiev dot ua
-Status:   Feedback
+Status:   Open
 Bug Type: Apache2 related
 Operating System: FreeBSD 6
 PHP Version:  5CVS, 4CVS (2005-11-11) (snap)
 New Comment:

HAVE_BROKEN_GETCWD is undefined
/* Define if system has broken getcwd */   

/* #undef HAVE_BROKEN_GETCWD */

And i used last LoadModule item for the php4_module in the httpd.conf:

LoadModule php4_module
/usr/home/samm/src/php4-STABLE-200511101949/libs/libphp4.so
   

Also i have

AddType application/x-httpd-php .php .phtml

to enable parsing of php.


Previous Comments:


[2005-11-11 00:44:11] [EMAIL PROTECTED]

And what is HAVE_BROKEN_GETCWD set to in the generated
main/php_config.h file?





[2005-11-11 00:35:26] [EMAIL PROTECTED]

How have you enabled PHP in your httpd.conf?
(what loadmodule/etc. lines you added)




[2005-11-11 00:32:19] [EMAIL PROTECTED]

The only file changed was sapi/apache2handler/sapi_apache2.c




[2005-11-11 00:27:40] [EMAIL PROTECTED]

Ah, thank you! This will help us pinpoint the problem very easily now.
I'll check what we changed between 4.4.0 / 4.4.1.




[2005-11-11 00:09:41] samm at os2 dot kiev dot ua

I tried to copy files from directory sapi/apache2handler of the
php4.4.0 to the latest 4.4-stable and than i recompiled php. After this
all path`s are displayed correctly, so problem is in the apache2handler
changes. Tomorrow i`ll try to make more detailt experiments to find a
change, which cause a regression.



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/35186

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


#35189 [NEW]: Date Function Bug

2005-11-10 Thread php at splitstreamdesign dot com
From: php at splitstreamdesign dot com
Operating system: Windows 2000/XP
PHP version:  5.0.5
PHP Bug Type: Date/time related
Bug description:  Date Function Bug

Description:

The documentation for the date() function states that the 'T' parameter
for the format string prints the timezone abbreviation: "Examples: EST,
MDT ...". Both PHP 5.0.4 and 5.0.5 replace 'T' with the full string
"Eastern Standard Time" on both Windows 2000 & Windows XP servers.

Reproduce code:
---


Expected result:

Fri, 11 Nov 2005 01:37:23 EST

Actual result:
--
Fri, 11 Nov 2005 01:37:23 Eastern Standard Time

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


#35188 [Bgs]: switch always picks case 0

2005-11-10 Thread daniel at assertio dot es
 ID:   35188
 User updated by:  daniel at assertio dot es
 Reported By:  daniel at assertio dot es
 Status:   Bogus
 Bug Type: Scripting Engine problem
 Operating System: Win XP
 PHP Version:  5.0.5
 New Comment:

Found it explained in
http://es.php.net/manual/en/language.operators.comparison.php

" If you compare an integer with a string, the string is converted to a
number."

hth...


Previous Comments:


[2005-11-11 03:56:44] [EMAIL PROTECTED]

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.





[2005-11-11 02:47:38] daniel at assertio dot es

Description:

If a switch case is 0 and the variable value evaluated in the switch is
a string, that case is picked.

Reproduce code:
---
$var = "hello";
switch($var){
case 0: 
echo "var is 0";
break;
default:
echo "default!";
}

Expected result:

default!

Actual result:
--
var is 0





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


#35186 [Opn]: getcwd() returns "/" when using with mod_rewrite

2005-11-10 Thread samm at os2 dot kiev dot ua
 ID:   35186
 User updated by:  samm at os2 dot kiev dot ua
 Reported By:  samm at os2 dot kiev dot ua
 Status:   Open
 Bug Type: Apache2 related
 Operating System: FreeBSD 6
 PHP Version:  5CVS, 4CVS (2005-11-11) (snap)
 New Comment:

I played with different version of the  sapi_apache2.c and found that
last working version was 1.1.2.40 and first failed was 1.1.2.40.2.5 . I
was unable to check versions between this, because they failed to work
with mod_rewrite giving no output at all. I hope, this help you.


Previous Comments:


[2005-11-11 06:27:55] samm at os2 dot kiev dot ua

HAVE_BROKEN_GETCWD is undefined
/* Define if system has broken getcwd */   

/* #undef HAVE_BROKEN_GETCWD */

And i used last LoadModule item for the php4_module in the httpd.conf:

LoadModule php4_module
/usr/home/samm/src/php4-STABLE-200511101949/libs/libphp4.so
   

Also i have

AddType application/x-httpd-php .php .phtml

to enable parsing of php.



[2005-11-11 00:44:11] [EMAIL PROTECTED]

And what is HAVE_BROKEN_GETCWD set to in the generated
main/php_config.h file?





[2005-11-11 00:35:26] [EMAIL PROTECTED]

How have you enabled PHP in your httpd.conf?
(what loadmodule/etc. lines you added)




[2005-11-11 00:32:19] [EMAIL PROTECTED]

The only file changed was sapi/apache2handler/sapi_apache2.c




[2005-11-11 00:27:40] [EMAIL PROTECTED]

Ah, thank you! This will help us pinpoint the problem very easily now.
I'll check what we changed between 4.4.0 / 4.4.1.




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/35186

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


#35155 [Asn->Bgs]: prepared statement with blob field does not work

2005-11-10 Thread georg
 ID:   35155
 Updated by:   [EMAIL PROTECTED]
 Reported By:  f dot engelhardt at 21torr dot com
-Status:   Assigned
+Status:   Bogus
 Bug Type: MySQLi related
 Operating System: Linux 2.6
 PHP Version:  5CVS-2005-11-09 (snap)
 Assigned To:  georg
 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

from http://www.php.net/mysql_stmt_bind_param

Character Description
b corresponding variable is a blob and will be send in
packages

For sending a blob in packages, you have to use
mysql_stmt_send_long_data. If you don't want to do this (e.g. your data
doesn't need escaping and is < max_allowed_package) use type "s"
(=string).


Previous Comments:


[2005-11-09 16:07:10] f dot engelhardt at 21torr dot com

This Problem is very annoying, becouse i am using innodb tables with
foreign key constraints, and if i use mysqli_stmt_send_long_data() for
any of the fields, all the other arent NULL anymore. So my constraint
fails!

Example:


without mysqli_stmt_send_long_data() i have the problem as described,
and with mysqli_stmt_send_long_data() on the blob field, mysql tells
me, that the constraint gets violated!
This can only happen, if the variables $one and $two are not  NULL.



[2005-11-08 23:28:54] [EMAIL PROTECTED]

Assigned to the maintainer.



[2005-11-08 23:26:59] f dot engelhardt at 21torr dot com

it doesn´t work, but the behavior changed a little:
Every insert without mysqli_stmt_send_long_data()
inserts 0 Bytes into the blob field, with this function
it works as in the other version (5.0.5)



[2005-11-08 17:43:53] [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-11-08 17:06:50] f dot engelhardt at 21torr dot com

it seems to work with mysqli_stmt_send_long_data(), but it has to work
without, as the doc says, you only have to use it, if you send data
larger than max_allowed_packet. This value is set to 16M, that data is
only 2mb.

Kind regards



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/35155

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