#31345 [NEW]: apache 1.3.31 / php5 / Oracle 10g

2004-12-30 Thread trade dot development at just dot fgov dot be
From: trade dot development at just dot fgov dot be
Operating system: AIX 5.3 5.3.0.0.10
PHP version:  5CVS-2004-12-30 (dev)
PHP Bug Type: *Compile Issues
Bug description:  apache 1.3.31 / php5 / Oracle 10g

Description:

1) Compiling without Oracle works : cfr php-qa
php_test_results_20041230_0754.txt

2) Compiling with Oracle not works
ld: 0711-736 ERROR: Input file
/opt/Oracle/app/oracle/OraHome_1/lib/libclntsh.so:
XCOFF64 object files are not allowed in 32-bit mode.
collect2: ld returned 8 exit status
make: 1254-004 The error code from the last command is 1.

3) Compiling with Oracle with workaround #31001 not works
-o libphp5.la
Assembler:
/tmp/ccmhBOP6.s: line 9,10,11,..,273: Only .llong should be used for
relocatable expressions.

collect2: gcc returned 1 exit status
make: 1254-004 The error code from the last command is 1.

4) workaround : change manualy Makefile oracle/lib with oracle/lib32 works
cfr php-qa php_test_results_20041230_0917.txt



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


#31345 [Opn]: AIX 5.3 lasfix 20041228 / apache 1.3.31 / php5 / Oracle 10g

2004-12-30 Thread trade dot development at just dot fgov dot be
 ID:   31345
 User updated by:  trade dot development at just dot fgov dot be
-Summary:  apache 1.3.31 / php5 / Oracle 10g
 Reported By:  trade dot development at just dot fgov dot be
 Status:   Open
 Bug Type: *Compile Issues
 Operating System: AIX 5.3 5.3.0.0.10
 PHP Version:  5CVS-2004-12-30 (dev)
 New Comment:

add os version in summary


Previous Comments:


[2004-12-30 09:57:45] trade dot development at just dot fgov dot be

Description:

1) Compiling without Oracle works : cfr php-qa
php_test_results_20041230_0754.txt

2) Compiling with Oracle not works
ld: 0711-736 ERROR: Input file
/opt/Oracle/app/oracle/OraHome_1/lib/libclntsh.so:
XCOFF64 object files are not allowed in 32-bit mode.
collect2: ld returned 8 exit status
make: 1254-004 The error code from the last command is 1.

3) Compiling with Oracle with workaround #31001 not works
-o libphp5.la
Assembler:
/tmp/ccmhBOP6.s: line 9,10,11,..,273: Only .llong should be used for
relocatable expressions.

collect2: gcc returned 1 exit status
make: 1254-004 The error code from the last command is 1.

4) workaround : change manualy Makefile oracle/lib with oracle/lib32
works cfr php-qa php_test_results_20041230_0917.txt







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


#31347 [NEW]: is_dir and is_file (incorrectly) return true for any string 255 characters

2004-12-30 Thread gilad dot buzi at concatel dot com
From: gilad dot buzi at concatel dot com
Operating system: Windows (2000/XP)
PHP version:  5.0.3
PHP Bug Type: *Directory/Filesystem functions
Bug description:  is_dir and is_file (incorrectly) return true for any string  
255 characters

Description:

is_dir() and is_file() (incorrectly) return true for any string larger
than 255 characters.

I tried this on two different machines, with the out of the box,
precompiled/downloaded Windows version of php 5.0.3.  No changes were made
to the standard php.ini-dist.  No extra extensions were loaded.  We are
using PHP as an Apache2 module (php2apache2.dll).  We also tried the
latest CVS snapshot (5CVS-2004-12-30 (dev)) and got the same results. 

We tried, and could NOT reproduce this on Linux.  It only failed on
windows platforms.  

Curiously (or maybe not so curious), file_exists() DOES work fine. 

Reproduce code:
---
?
$myfilename=aaaccsaccss;
echo myfilename is: $myfilename;
echo brmyfilename is .strlen($myfilename). characters long;
echo bris_dir: .is_dir($myfilename);
echo brfile_exists: .file_exists($myfilename);
echo bris_file: .is_file($myfilename);

$myfilename=ccsaccss;
echo brbrmyfilename is: $myfilename;
echo brmyfilename is .strlen($myfilename). characters long;
echo bris_dir: .is_dir($myfilename);
echo brfile_exists: .file_exists($myfilename);
echo bris_file: .is_file($myfilename);
?

Expected result:

is_dir() and is_file() should return false if the file or directory does
not exist, regardless of the length of the string they are passed.



Actual result:
--
Result for above script is:
myfilename is:
aaaccsaccss
myfilename is 255 characters long
is_dir:
file_exists:
is_file:

myfilename is:
ccsaccss
myfilename is 256 characters long
is_dir: 1
file_exists: 1
is_file:

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


#31348 [NEW]: CachingIterator::rewind() leaks

2004-12-30 Thread tony2001 at phpclub dot net
From: tony2001 at phpclub dot net
Operating system: Linux 2.6.9
PHP version:  5CVS-2004-12-30 (dev)
PHP Bug Type: SPL related
Bug description:  CachingIterator::rewind() leaks 

Description:

CachingIterator::rewind() leaks some memory.
I can propose this small patch, but I'm almost sure it's not the real
solution.

Index: spl_iterators.c
===
RCS file: /repository/php-src/ext/spl/spl_iterators.c,v
retrieving revision 1.61
diff -u -r1.61 spl_iterators.c
--- spl_iterators.c 29 Dec 2004 16:11:42 -  1.61
+++ spl_iterators.c 30 Dec 2004 09:43:14 -
@@ -752,7 +752,8 @@
}
if (intern-dit_type == DIT_CachingIterator || intern-dit_type ==
DIT_CachingRecursiveIterator) {
if (intern-u.caching.zstr) {
-   zval_ptr_dtor(intern-u.caching.zstr);
+   zval_dtor(intern-u.caching.zstr);
+   FREE_ZVAL(intern-u.caching.zstr);
intern-u.caching.zstr = NULL;
}
if (intern-u.caching.zchildren) {

Reproduce code:
---
?php
$a = Array(some,blah);
$i = new ArrayIterator($a);

$ci = new CachingIterator($i);

$ci-rewind();

echo Done\n;
?

Expected result:

Done

Actual result:
--
Done
/home/dev/php-src/ext/spl/spl_iterators.c(1276) :  Freeing 0x082E9064 (16
bytes), script=/www/index.php
/home/dev/php-src/Zend/zend_variables.h(45) :  Freeing 0x082E8E9C (5
bytes), script=/www/index.php
/home/dev/php-src/Zend/zend_variables.c(120) : Actual location (location
was relayed)
=== Total 2 memory leaks detected ===

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


#31348 [Opn-Asn]: CachingIterator::rewind() leaks

2004-12-30 Thread tony2001
 ID:   31348
 Updated by:   [EMAIL PROTECTED]
 Reported By:  tony2001 at phpclub dot net
-Status:   Open
+Status:   Assigned
 Bug Type: SPL related
 Operating System: Linux 2.6.9
 PHP Version:  5CVS-2004-12-30 (dev)
-Assigned To:  
+Assigned To:  helly


Previous Comments:


[2004-12-30 10:46:51] tony2001 at phpclub dot net

Description:

CachingIterator::rewind() leaks some memory.
I can propose this small patch, but I'm almost sure it's not the real
solution.

Index: spl_iterators.c
===
RCS file: /repository/php-src/ext/spl/spl_iterators.c,v
retrieving revision 1.61
diff -u -r1.61 spl_iterators.c
--- spl_iterators.c 29 Dec 2004 16:11:42 -  1.61
+++ spl_iterators.c 30 Dec 2004 09:43:14 -
@@ -752,7 +752,8 @@
}
if (intern-dit_type == DIT_CachingIterator || intern-dit_type
== DIT_CachingRecursiveIterator) {
if (intern-u.caching.zstr) {
-   zval_ptr_dtor(intern-u.caching.zstr);
+   zval_dtor(intern-u.caching.zstr);
+   FREE_ZVAL(intern-u.caching.zstr);
intern-u.caching.zstr = NULL;
}
if (intern-u.caching.zchildren) {

Reproduce code:
---
?php
$a = Array(some,blah);
$i = new ArrayIterator($a);

$ci = new CachingIterator($i);

$ci-rewind();

echo Done\n;
?

Expected result:

Done

Actual result:
--
Done
/home/dev/php-src/ext/spl/spl_iterators.c(1276) :  Freeing 0x082E9064
(16 bytes), script=/www/index.php
/home/dev/php-src/Zend/zend_variables.h(45) :  Freeing 0x082E8E9C (5
bytes), script=/www/index.php
/home/dev/php-src/Zend/zend_variables.c(120) : Actual location
(location was relayed)
=== Total 2 memory leaks detected ===





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


#31346 [Opn-Asn]: ArrayIterator::next segfaults

2004-12-30 Thread tony2001
 ID:   31346
 Updated by:   [EMAIL PROTECTED]
 Reported By:  tony2001 at phpclub dot net
-Status:   Open
+Status:   Assigned
 Bug Type: SPL related
 Operating System: Linux 2.6.9
 PHP Version:  5CVS-2004-12-30 (dev)
-Assigned To:  
+Assigned To:  helly


Previous Comments:


[2004-12-30 10:15:36] tony2001 at phpclub dot net

Description:

ArrayIterator::next() segfaults when called after
ArrayIterator::offsetUnset().


Reproduce code:
---
?php
$obj = new stdClass;
$obj-var1=1;

$ao = new ArrayObject($obj);

$i = $ao-getIterator();

$ao-offsetUnset($i-key());
$i-next();
echo Done;
?

Expected result:

Done

Actual result:
--
Program received signal SIGSEGV, Segmentation fault.
0x0818148b in zend_hash_get_current_key_ex (ht=0x82e44ac,
str_index=0xbfffd1c4, str_length=0xbfffd1c0,
num_index=0xbfffd1bc, duplicate=0 '\0', pos=0x82e919c) at
/home/dev/php-src/Zend/zend_hash.c:1055
1055if (p-nKeyLength) {
(gdb) bt
#0  0x0818148b in zend_hash_get_current_key_ex (ht=0x82e44ac,
str_index=0xbfffd1c4, str_length=0xbfffd1c0,
num_index=0xbfffd1bc, duplicate=0 '\0', pos=0x82e919c) at
/home/dev/php-src/Zend/zend_hash.c:1055
#1  0x080aff15 in spl_array_skip_protected (intern=0x82e918c) at
/home/dev/php-src/ext/spl/spl_array.c:479
#2  0x080b000b in spl_array_next (intern=0x82e918c) at
/home/dev/php-src/ext/spl/spl_array.c:502
#3  0x080b0d8e in zif_spl_Array_next (ht=0, return_value=0x82e9054,
this_ptr=0x82e90f4, return_value_used=0)
at /home/dev/php-src/ext/spl/spl_array.c:857
#4  0x0819c493 in zend_do_fcall_common_helper_SPEC
(execute_data=0xbfffd430) at zend_vm_execute.h:155
#5  0x0819ca01 in ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER
(execute_data=0xbfffd430) at zend_vm_execute.h:268
#6  0x0819c1ab in execute (op_array=0x82e43ec) at zend_vm_execute.h:58
#7  0x081793b7 in zend_execute_scripts (type=8, retval=0x0,
file_count=3) at /home/dev/php-src/Zend/zend.c:1062
#8  0x08139647 in php_execute_script (primary_file=0xb840) at
/home/dev/php-src/main/main.c:1639
#9  0x081e92b5 in main (argc=2, argv=0xb8d4) at
/home/dev/php-src/sapi/cli/php_cli.c:944
#10 0x420157a4 in __libc_start_main () from /lib/tls/libc.so.6





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


#31332 [Com]: unserialize() works terribly slow on huge strings compared to 4.3.9

2004-12-30 Thread chris-php at bolt dot cx
 ID:   31332
 Comment by:   chris-php at bolt dot cx
 Reported By:  marekm at apnet dot pl
 Status:   Open
 Bug Type: Performance problem
 Operating System: Win32/Linux
 PHP Version:  4.3.10
 New Comment:

Pretty sure we're getting hit by this as well. We use serialize a lot
(memcached), and upgrading from PHP 4.3.9 to 4.3.10 tripled our
servers' load averages.


Previous Comments:


[2004-12-29 12:30:09] marekm at apnet dot pl

Description:

I keep big multidimensional arrays serialize()'d into strings in
database.
After upgrade from 4.3.9 - 4.3.10 I noticed, that unserialize()
function on some of them work even 20 times slower. On other the
slowdown is minimal. 

Reproduce code:
---
?
function getmicrotime() 
{ 
list($usec, $sec) = explode( , microtime()); 
return ((float)$usec + (float)$sec); 
} 

$f=fopen(serialized.txt,r);
$l1=fgets($f,100);
fclose($f);

$t1=getmicrotime();
$a=unserialize($l1);
echo(getmicrotime()-$t1);
?

The tested serialized.txt file can be downloaded from
http://ap.aptus.pl/serialized.txt

Expected result:

The above script working as fast as in 4.3.9

Actual result:
--
The script works about 20x slower.





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


#31346 [NEW]: ArrayIterator::next segfaults

2004-12-30 Thread tony2001 at phpclub dot net
From: tony2001 at phpclub dot net
Operating system: Linux 2.6.9
PHP version:  5CVS-2004-12-30 (dev)
PHP Bug Type: SPL related
Bug description:  ArrayIterator::next segfaults

Description:

ArrayIterator::next() segfaults when called after
ArrayIterator::offsetUnset().


Reproduce code:
---
?php
$obj = new stdClass;
$obj-var1=1;

$ao = new ArrayObject($obj);

$i = $ao-getIterator();

$ao-offsetUnset($i-key());
$i-next();
echo Done;
?

Expected result:

Done

Actual result:
--
Program received signal SIGSEGV, Segmentation fault.
0x0818148b in zend_hash_get_current_key_ex (ht=0x82e44ac,
str_index=0xbfffd1c4, str_length=0xbfffd1c0,
num_index=0xbfffd1bc, duplicate=0 '\0', pos=0x82e919c) at
/home/dev/php-src/Zend/zend_hash.c:1055
1055if (p-nKeyLength) {
(gdb) bt
#0  0x0818148b in zend_hash_get_current_key_ex (ht=0x82e44ac,
str_index=0xbfffd1c4, str_length=0xbfffd1c0,
num_index=0xbfffd1bc, duplicate=0 '\0', pos=0x82e919c) at
/home/dev/php-src/Zend/zend_hash.c:1055
#1  0x080aff15 in spl_array_skip_protected (intern=0x82e918c) at
/home/dev/php-src/ext/spl/spl_array.c:479
#2  0x080b000b in spl_array_next (intern=0x82e918c) at
/home/dev/php-src/ext/spl/spl_array.c:502
#3  0x080b0d8e in zif_spl_Array_next (ht=0, return_value=0x82e9054,
this_ptr=0x82e90f4, return_value_used=0)
at /home/dev/php-src/ext/spl/spl_array.c:857
#4  0x0819c493 in zend_do_fcall_common_helper_SPEC
(execute_data=0xbfffd430) at zend_vm_execute.h:155
#5  0x0819ca01 in ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER
(execute_data=0xbfffd430) at zend_vm_execute.h:268
#6  0x0819c1ab in execute (op_array=0x82e43ec) at zend_vm_execute.h:58
#7  0x081793b7 in zend_execute_scripts (type=8, retval=0x0, file_count=3)
at /home/dev/php-src/Zend/zend.c:1062
#8  0x08139647 in php_execute_script (primary_file=0xb840) at
/home/dev/php-src/main/main.c:1639
#9  0x081e92b5 in main (argc=2, argv=0xb8d4) at
/home/dev/php-src/sapi/cli/php_cli.c:944
#10 0x420157a4 in __libc_start_main () from /lib/tls/libc.so.6

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


#31339 [Opn-Bgs]: Strange parser errors with eval

2004-12-30 Thread derick
 ID:   31339
 Updated by:   [EMAIL PROTECTED]
 Reported By:  bart at mediawave dot nl
-Status:   Open
+Status:   Bogus
 Bug Type: Scripting Engine problem
 Operating System: WinXP
 PHP Version:  5.0.3
 New Comment:

You need to escape use of vars inside your eval'ed string otherwise
they are substituted with the value. Your eval'ed code looks like
something like:

echo hello;

'Why did the chicken cross the road?' = 'Why did the chicken cross the
road?'

which obviously is wrong


Previous Comments:


[2004-12-30 00:20:17] bart at mediawave dot nl

Description:

My script depends heavily on eval and since I upgraded to PHP 5.0.3
everything completely broke down. (I think I was using 5.0.0 before I
upgraded) (And yes, I know, Using eval() is a very dirty thing to do ;)
)

After hours and hours of pinpointing I found out that things go wrong
when code is running through eval(). The same code running directly
(without eval()) runs flawlessly. It looks like there are some parsing
problems with eval() or something.

I'm also getting weird ODBC problems as soon as correctly working code
runs through eval():

Warning: odbc_exec(): SQL error: [Microsoft][ODBC Microsoft Access
Driver]Invalid use of null pointer , SQL state S1009 in SQLExecDirect
in D:\php\includes\sp6\modules\bwceval.php(33) : eval()'d code on line
24 

I got the above warning out of the command line version of PHP since
IIS only gave me a:

CGI Error
The specified CGI application misbehaved by not returning a complete
set of HTTP headers. The headers it did return are:

Anywayz. I've got some very simple code that reproduces my problem:

Reproduce code:
---
?php 

echo 'hello';

$myvar = 'Why did the chicken cross the road?';

$string = 

echo 'hello';

$myvar = 'Why did the chicken cross the road?';
  
;

eval ($string);

?

Expected result:

hellohello

Actual result:
--
hello
Parse error: syntax error, unexpected T_STRING in
D:\Inetpub\wwwroot\test4.php(24) : eval()'d code on line 5





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


#31324 [Opn-Fbk]: function strlen miscounts

2004-12-30 Thread derick
 ID:   31324
 Updated by:   [EMAIL PROTECTED]
 Reported By:  phpbug at tore dot cc
-Status:   Open
+Status:   Feedback
 Bug Type: Strings related
 Operating System: Solaris 10
 PHP Version:  5.0.2
 New Comment:

It's impossible to extract that code from PHP, and as we don't have
access to a solaris machine we can not really debug this.


Previous Comments:


[2004-12-29 23:22:50] phpbug at tore dot cc

Are 64bit processors not supported by php?
Which machine architecture is 'my system'?

The php is compiled with gcc2 AND gcc3. With solaris 9 AND solaris 10.
The same trouble occurs.
So I need to have the code for 'strlen' in php extracted before I can
figure out where the source for the trouble is.

A simple C-program using string.h's strlen cause no troule at all.



[2004-12-29 21:42:53] [EMAIL PROTECTED]

Sounds like either a compiler or libc bug. I cannot replicate this on
my systems either.



[2004-12-29 19:13:28] phpbug at tore dot cc

I might add that I tried php-5.0.3 on an intel-based solaris 10 machine
and there were no problems with the strlen.



[2004-12-29 07:34:41] phpbug at tore dot cc

I have used gcc2 and gcc3 to compile.
The machine is a sparc.
The problem occurs on solaris 9 and solaris 10.
If you suspect that this is a solaris problem, can you extract the code
for 'strlen' in php. I could make some tests in C



[2004-12-28 23:59:37] [EMAIL PROTECTED]

It still works fine for me on Linux. Which compiler did you use to
compile PHP (gcc or sun workshop), and what kind of platform do you
use? intel (32/64), sparc...



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

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


#31339 [Bgs-Opn]: Strange parser errors with eval

2004-12-30 Thread bart at mediawave dot nl
 ID:   31339
 User updated by:  bart at mediawave dot nl
 Reported By:  bart at mediawave dot nl
-Status:   Bogus
+Status:   Open
 Bug Type: Scripting Engine problem
 Operating System: WinXP
 PHP Version:  5.0.3
 New Comment:

damned... Now I feel really stupid...


Previous Comments:


[2004-12-30 10:58:23] [EMAIL PROTECTED]

You need to escape use of vars inside your eval'ed string otherwise
they are substituted with the value. Your eval'ed code looks like
something like:

echo hello;

'Why did the chicken cross the road?' = 'Why did the chicken cross the
road?'

which obviously is wrong



[2004-12-30 00:20:17] bart at mediawave dot nl

Description:

My script depends heavily on eval and since I upgraded to PHP 5.0.3
everything completely broke down. (I think I was using 5.0.0 before I
upgraded) (And yes, I know, Using eval() is a very dirty thing to do ;)
)

After hours and hours of pinpointing I found out that things go wrong
when code is running through eval(). The same code running directly
(without eval()) runs flawlessly. It looks like there are some parsing
problems with eval() or something.

I'm also getting weird ODBC problems as soon as correctly working code
runs through eval():

Warning: odbc_exec(): SQL error: [Microsoft][ODBC Microsoft Access
Driver]Invalid use of null pointer , SQL state S1009 in SQLExecDirect
in D:\php\includes\sp6\modules\bwceval.php(33) : eval()'d code on line
24 

I got the above warning out of the command line version of PHP since
IIS only gave me a:

CGI Error
The specified CGI application misbehaved by not returning a complete
set of HTTP headers. The headers it did return are:

Anywayz. I've got some very simple code that reproduces my problem:

Reproduce code:
---
?php 

echo 'hello';

$myvar = 'Why did the chicken cross the road?';

$string = 

echo 'hello';

$myvar = 'Why did the chicken cross the road?';
  
;

eval ($string);

?

Expected result:

hellohello

Actual result:
--
hello
Parse error: syntax error, unexpected T_STRING in
D:\Inetpub\wwwroot\test4.php(24) : eval()'d code on line 5





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


#31339 [Opn-Bgs]: Strange parser errors with eval

2004-12-30 Thread bart at mediawave dot nl
 ID:   31339
 User updated by:  bart at mediawave dot nl
 Reported By:  bart at mediawave dot nl
-Status:   Open
+Status:   Bogus
 Bug Type: Scripting Engine problem
 Operating System: WinXP
 PHP Version:  5.0.3
 New Comment:

whoops... bag to Bogus again...


Previous Comments:


[2004-12-30 11:09:23] bart at mediawave dot nl

damned... Now I feel really stupid...



[2004-12-30 10:58:23] [EMAIL PROTECTED]

You need to escape use of vars inside your eval'ed string otherwise
they are substituted with the value. Your eval'ed code looks like
something like:

echo hello;

'Why did the chicken cross the road?' = 'Why did the chicken cross the
road?'

which obviously is wrong



[2004-12-30 00:20:17] bart at mediawave dot nl

Description:

My script depends heavily on eval and since I upgraded to PHP 5.0.3
everything completely broke down. (I think I was using 5.0.0 before I
upgraded) (And yes, I know, Using eval() is a very dirty thing to do ;)
)

After hours and hours of pinpointing I found out that things go wrong
when code is running through eval(). The same code running directly
(without eval()) runs flawlessly. It looks like there are some parsing
problems with eval() or something.

I'm also getting weird ODBC problems as soon as correctly working code
runs through eval():

Warning: odbc_exec(): SQL error: [Microsoft][ODBC Microsoft Access
Driver]Invalid use of null pointer , SQL state S1009 in SQLExecDirect
in D:\php\includes\sp6\modules\bwceval.php(33) : eval()'d code on line
24 

I got the above warning out of the command line version of PHP since
IIS only gave me a:

CGI Error
The specified CGI application misbehaved by not returning a complete
set of HTTP headers. The headers it did return are:

Anywayz. I've got some very simple code that reproduces my problem:

Reproduce code:
---
?php 

echo 'hello';

$myvar = 'Why did the chicken cross the road?';

$string = 

echo 'hello';

$myvar = 'Why did the chicken cross the road?';
  
;

eval ($string);

?

Expected result:

hellohello

Actual result:
--
hello
Parse error: syntax error, unexpected T_STRING in
D:\Inetpub\wwwroot\test4.php(24) : eval()'d code on line 5





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


#31146 [Opn]: default_charset variable is not used

2004-12-30 Thread sniper
 ID:   31146
 Updated by:   [EMAIL PROTECTED]
 Reported By:  mitya at demos dot su
 Status:   Open
 Bug Type: PHP options/info functions
 Operating System: Solaris 9
 PHP Version:  4.3.10
 New Comment:

I've never had magic_quotes_gpc set to anything but 'off'. 
So I still can't reproduce this.



Previous Comments:


[2004-12-24 12:59:37] mitya at demos dot su

The problem becomes much less bogus if I add the following
information:

1) I use apache from Solaris packages (SUNWapchr, SUNWapchu)
with the latest patches available (113146-06)
2) The vital part of php.ini to reproduce the problem is:
magic_quotes_gpc = Off

Without this line the problem does not exist.
To reveal the problem use the following php.ini:
[PHP]
magic_quotes_gpc = Off
default_charset = koi8-r



[2004-12-17 14:44:45] [EMAIL PROTECTED]

Works fine for me too. (apache 1.3.28 too)




[2004-12-17 10:36:54] [EMAIL PROTECTED]

I can not reproduce this, it works fine for me. (On both PHP 4 and 5).



[2004-12-17 10:31:06] mitya at demos dot su

Description:

I am using PHP 4.3.10 with Apache 1.3.29 as DSO module.
I changed default_charset variable in php.ini to a custom
value (koi8-r).  phpinfo() reports that the value of this variable is
in fact koi8-r.

But HTTP headers for any PHP page on my server looks as follows:
Content-type=text/html; charset=

that is charset is empty.

I wonder is it a bug or an intended behaviour (what are the reasons to
not apply the value of charset specified in php.ini in that case)?

Thanks in advance!






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


#31349 [NEW]: Segmentation fault in mysql_query()

2004-12-30 Thread bugs dot php dot net at chsc dot dk
From: bugs dot php dot net at chsc dot dk
Operating system: Linux
PHP version:  5.0.3
PHP Bug Type: MySQL related
Bug description:  Segmentation fault in mysql_query()

Description:

I have a rather complex script that dumps core every time mysql_query() is
called for the 7th time (through PEAR's DB_mysql).

The script uses Smarty, PEAR_DB and a bunch of other classes. I have not
been able to make a simple testcase. Doing the seven SQL queries alone
without Smarty and all the other code does not trigger this bug. I hope
that a stack trace will point in the right direction though.

The problem occurs with two different MySQL versions:
mysql  Ver 12.22 Distrib 4.0.20, for pc-linux (i686)
mysql  Ver 14.7 Distrib 4.1.8, for pc-linux (i686)

The problem can be reproduced on two different machines.

I am using PHP 5.0.3. The problem wasn't there with PHP 5.0.2.

PHP was configured like this:
'./configure' '--with-mysql=/usr/local/mysql' '--with-apache=../apache'
'--enable-track-vars' '--with-gettext' '--with-dom' '--with-mcrypt'
'--with-gd' '--with-jpeg-dir' '--with-png-dir' '--with-zlib-dir'
'--with-freetype-dir' '--with-pear' '--enable-mbstring' '--with-iconv'
'--disable-debug' '--enable-soap'


This is a stacktrace of the failure:

# gdb /usr/local/apache/bin/httpd
GNU gdb 2002-04-01-cvs
Copyright 2002 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you
are
welcome to change it and/or distribute copies of it under certain
conditions.
Type show copying to see the conditions.
There is absolutely no warranty for GDB.  Type show warranty for
details.
This GDB was configured as i386-linux...(no debugging symbols found)...
(gdb) run -X
Starting program: /usr/local/apache/bin/httpd -X
(no debugging symbols found)...[New Thread 1024 (LWP 31535)]

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 1024 (LWP 31535)]
0x403d61b7 in memcpy () from /lib/libc.so.6
(gdb) bt
#0  0x403d61b7 in memcpy () from /lib/libc.so.6
#1  0x0829a104 in cli_read_rows ()
#2  0x0829b942 in mysql_close ()
#3  0x0829ba50 in mysql_real_query ()
#4  0x0817446e in zif_mysql_client_encoding ()
#5  0x0817460c in zif_mysql_client_encoding ()
#6  0x08174630 in zif_mysql_query ()
#7  0x08113a5a in zend_do_fcall_common_helper ()
#8  0x08114091 in zend_do_fcall_handler ()
#9  0x080fc375 in execute ()
#10 0x08113b42 in zend_do_fcall_common_helper ()
#11 0x08113e99 in zend_do_fcall_by_name_handler ()
#12 0x080fc375 in execute ()
#13 0x08113b42 in zend_do_fcall_common_helper ()
#14 0x08113e99 in zend_do_fcall_by_name_handler ()
#15 0x080fc375 in execute ()
#16 0x08113b42 in zend_do_fcall_common_helper ()
#17 0x08113e99 in zend_do_fcall_by_name_handler ()
#18 0x080fc375 in execute ()
#19 0x08113b42 in zend_do_fcall_common_helper ()
#20 0x08113e99 in zend_do_fcall_by_name_handler ()
#21 0x080fc375 in execute ()
#22 0x08113b42 in zend_do_fcall_common_helper ()
---Type return to continue, or q return to quit---
#23 0x08113e99 in zend_do_fcall_by_name_handler ()
#24 0x080fc375 in execute ()
#25 0x08113b42 in zend_do_fcall_common_helper ()
#26 0x08113e99 in zend_do_fcall_by_name_handler ()
#27 0x080fc375 in execute ()
#28 0x08113b42 in zend_do_fcall_common_helper ()
#29 0x08113e99 in zend_do_fcall_by_name_handler ()
#30 0x080fc375 in execute ()
#31 0x08113b42 in zend_do_fcall_common_helper ()
#32 0x08113e99 in zend_do_fcall_by_name_handler ()
#33 0x080fc375 in execute ()
#34 0x08113b42 in zend_do_fcall_common_helper ()
#35 0x08113e99 in zend_do_fcall_by_name_handler ()
#36 0x080fc375 in execute ()
#37 0x08118cd6 in zend_include_or_eval_handler ()
#38 0x080fc375 in execute ()
#39 0x08113b42 in zend_do_fcall_common_helper ()
#40 0x08113e99 in zend_do_fcall_by_name_handler ()
#41 0x080fc375 in execute ()
#42 0x08118cd6 in zend_include_or_eval_handler ()
#43 0x080fc375 in execute ()
#44 0x08113b42 in zend_do_fcall_common_helper ()
#45 0x08113e99 in zend_do_fcall_by_name_handler ()
---Type return to continue, or q return to quit---
#46 0x080fc375 in execute ()
#47 0x08113b42 in zend_do_fcall_common_helper ()
#48 0x08113e99 in zend_do_fcall_by_name_handler ()
#49 0x080fc375 in execute ()
#50 0x08113b42 in zend_do_fcall_common_helper ()
#51 0x08113e99 in zend_do_fcall_by_name_handler ()
#52 0x080fc375 in execute ()
#53 0x08113b42 in zend_do_fcall_common_helper ()
#54 0x08113e99 in zend_do_fcall_by_name_handler ()
#55 0x080fc375 in execute ()
#56 0x080e1a68 in zend_execute_scripts ()
#57 0x080b98da in php_execute_script ()
#58 0x0811b712 in apache_php_module_main ()
#59 0x080b22f2 in ssl_expr_yyinput ()
#60 0x080b2341 in ssl_expr_yyinput ()
#61 0x0825b364 in ap_invoke_handler ()
#62 0x0826b74c in ap_some_auth_required ()
#63 0x0826ba50 in ap_internal_redirect ()
#64 0x08096c6c in ap_get_server_built ()
#65 0x0825b364 in ap_invoke_handler ()
#66 0x0826b74c in ap_some_auth_required ()
#67 0x0826b7a8 in ap_process_request ()
#68 0x08264d57 in ap_child_terminate ()

#31350 [NEW]: Max reading length of STDIN is 8192bytes

2004-12-30 Thread gibspam at carnation dot hu
From: gibspam at carnation dot hu
Operating system: Redhat Linux 7.1-7.3
PHP version:  4.3.10
PHP Bug Type: Filesystem function related
Bug description:  Max reading length of STDIN is 8192bytes

Description:

I write a script which reads a file from STDIN, and writes it out the
content of it to a new file. It worked fine with php 4.3.4, but when I
upgraded to any newer version, then it failed to read the whole file from
stdin. I expected to read the file into a 128000 bytes buffer but it reads
only 8192 bytes instead of 128000 bytes.

Reproduce code:
---
?
$file_length = 6596594;
define(UPLOAD_BUFFER,128000);

if (!$fp = fopen(test.data,w))
{
die(file open error);
}

$count =  (($file_length / UPLOAD_BUFFER));
echo \nmax i should be: .$count;
for ($i = 1; $i  $count; $i ++) {
$str = fread(STDIN, UPLOAD_BUFFER);
echo \ni: .$i. length:.strlen($str);
fwrite($fp, $str);
}

$remainder = $file_length % UPLOAD_BUFFER;

if (0 != $remainder) {
$str = fread(STDIN, $remainder);
echo \nlast length:.strlen($str);
fwrite($fp, fread(STDIN, $remainder));
}

fclose($fp);
?


Expected result:

If I run my script with this command:
php -q ./my.php  file_with_size_of_6596594_bytes.bin

I expect to get a new file created (test.data), with the same content as
the file_with_size_of_6596594_bytes.bin.

Actual result:
--
As a result a new file created (test.data), which is 425984 bytes long.

425984=51*8192+8192

But, it shuld be

6596594=51*128000+68594



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


#31344 [Com]: PHP 4.3.10 crashed Apache without message

2004-12-30 Thread egor at ensita dot net
 ID:   31344
 Comment by:   egor at ensita dot net
 Reported By:  sysadmin at amhosting dot com
 Status:   Feedback
 Bug Type: Apache2 related
 Operating System: Red Hat 9 + Legacy
 PHP Version:  4.3.10
 New Comment:

the latest stable doesn't help. :(


Previous Comments:


[2004-12-30 08:10:14] [EMAIL PROTECTED]

Please try using this CVS snapshot:

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





[2004-12-30 07:51:26] sysadmin at amhosting dot com

Description:

In trying to upgrade my Plesk servers, I have found that one upgrade
worked, the rest bombed out.  To reduce the number of variables, I
built a Red Hat 9 server from CDs, installed Yum, ran a full upgrade
cycle, then tried to install 4.3.10.  Apache would not start, or would
crash immediately without any tombstones.

Reproduce code:
---
Load Red Hat 9 from CDs.
Install Yum per instructions from Fedora Legacy project
yum update
download php source.
./configure parameters
make
make install

Expected result:

I expected PHP 4.3.10 to install and run normally.

Actual result:
--
Apache died without a trace.  service httpd status said that the
service was dead but a PID file was in place.





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


#31344 [Fbk]: PHP 4.3.10 crashed Apache without message

2004-12-30 Thread tony2001
 ID:   31344
 Updated by:   [EMAIL PROTECTED]
 Reported By:  sysadmin at amhosting dot com
 Status:   Feedback
 Bug Type: Apache2 related
 Operating System: Red Hat 9 + Legacy
 PHP Version:  4.3.10
 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 ?php and ends 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 avoid embedding huge scripts into the report.




Previous Comments:


[2004-12-30 13:22:50] egor at ensita dot net

the latest stable doesn't help. :(



[2004-12-30 08:10:14] [EMAIL PROTECTED]

Please try using this CVS snapshot:

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





[2004-12-30 07:51:26] sysadmin at amhosting dot com

Description:

In trying to upgrade my Plesk servers, I have found that one upgrade
worked, the rest bombed out.  To reduce the number of variables, I
built a Red Hat 9 server from CDs, installed Yum, ran a full upgrade
cycle, then tried to install 4.3.10.  Apache would not start, or would
crash immediately without any tombstones.

Reproduce code:
---
Load Red Hat 9 from CDs.
Install Yum per instructions from Fedora Legacy project
yum update
download php source.
./configure parameters
make
make install

Expected result:

I expected PHP 4.3.10 to install and run normally.

Actual result:
--
Apache died without a trace.  service httpd status said that the
service was dead but a PID file was in place.





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


#31324 [Fbk-Opn]: function strlen miscounts

2004-12-30 Thread phpbug at tore dot cc
 ID:   31324
 User updated by:  phpbug at tore dot cc
 Reported By:  phpbug at tore dot cc
-Status:   Feedback
+Status:   Open
 Bug Type: Strings related
 Operating System: Solaris 10
 PHP Version:  5.0.2
 New Comment:

I have traced down the trouble.
When multibyte strings support is complied in to php the internal
function 'strlen' is aliased to the function 'mb_strlen'.
mb_strlen counts the number of characters in the binary string
depending of what default encoding is used.

I have set the default chars to UTF-8 and SJIS (japanese) on my sparc
machine. That is why I only see it there.

Please remove the aliasing between strlen and mb_strlen!


Previous Comments:


[2004-12-30 10:55:57] [EMAIL PROTECTED]

It's impossible to extract that code from PHP, and as we don't have
access to a solaris machine we can not really debug this.



[2004-12-29 23:22:50] phpbug at tore dot cc

Are 64bit processors not supported by php?
Which machine architecture is 'my system'?

The php is compiled with gcc2 AND gcc3. With solaris 9 AND solaris 10.
The same trouble occurs.
So I need to have the code for 'strlen' in php extracted before I can
figure out where the source for the trouble is.

A simple C-program using string.h's strlen cause no troule at all.



[2004-12-29 21:42:53] [EMAIL PROTECTED]

Sounds like either a compiler or libc bug. I cannot replicate this on
my systems either.



[2004-12-29 19:13:28] phpbug at tore dot cc

I might add that I tried php-5.0.3 on an intel-based solaris 10 machine
and there were no problems with the strlen.



[2004-12-29 07:34:41] phpbug at tore dot cc

I have used gcc2 and gcc3 to compile.
The machine is a sparc.
The problem occurs on solaris 9 and solaris 10.
If you suspect that this is a solaris problem, can you extract the code
for 'strlen' in php. I could make some tests in C



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

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


#31349 [Opn]: Segmentation fault in mysql_query()

2004-12-30 Thread bugs dot php dot net at chsc dot dk
 ID:   31349
 User updated by:  bugs dot php dot net at chsc dot dk
 Reported By:  bugs dot php dot net at chsc dot dk
 Status:   Open
 Bug Type: MySQL related
 Operating System: Linux
 PHP Version:  5.0.3
 New Comment:

I appears that if I change the queries slightly, e.g. add a /* comment
*/ to the end of the SQL string, or remove additional whitespace
outsite strings, everything works as expected.

It may be related to this bug: http://bugs.mysql.com/bug.php?id=5607


Previous Comments:


[2004-12-30 11:56:20] bugs dot php dot net at chsc dot dk

Description:

I have a rather complex script that dumps core every time mysql_query()
is called for the 7th time (through PEAR's DB_mysql).

The script uses Smarty, PEAR_DB and a bunch of other classes. I have
not been able to make a simple testcase. Doing the seven SQL queries
alone without Smarty and all the other code does not trigger this bug.
I hope that a stack trace will point in the right direction though.

The problem occurs with two different MySQL versions:
mysql  Ver 12.22 Distrib 4.0.20, for pc-linux (i686)
mysql  Ver 14.7 Distrib 4.1.8, for pc-linux (i686)

The problem can be reproduced on two different machines.

I am using PHP 5.0.3. The problem wasn't there with PHP 5.0.2.

PHP was configured like this:
'./configure' '--with-mysql=/usr/local/mysql' '--with-apache=../apache'
'--enable-track-vars' '--with-gettext' '--with-dom' '--with-mcrypt'
'--with-gd' '--with-jpeg-dir' '--with-png-dir' '--with-zlib-dir'
'--with-freetype-dir' '--with-pear' '--enable-mbstring' '--with-iconv'
'--disable-debug' '--enable-soap'


This is a stacktrace of the failure:

# gdb /usr/local/apache/bin/httpd
GNU gdb 2002-04-01-cvs
Copyright 2002 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and
you are
welcome to change it and/or distribute copies of it under certain
conditions.
Type show copying to see the conditions.
There is absolutely no warranty for GDB.  Type show warranty for
details.
This GDB was configured as i386-linux...(no debugging symbols
found)...
(gdb) run -X
Starting program: /usr/local/apache/bin/httpd -X
(no debugging symbols found)...[New Thread 1024 (LWP 31535)]

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 1024 (LWP 31535)]
0x403d61b7 in memcpy () from /lib/libc.so.6
(gdb) bt
#0  0x403d61b7 in memcpy () from /lib/libc.so.6
#1  0x0829a104 in cli_read_rows ()
#2  0x0829b942 in mysql_close ()
#3  0x0829ba50 in mysql_real_query ()
#4  0x0817446e in zif_mysql_client_encoding ()
#5  0x0817460c in zif_mysql_client_encoding ()
#6  0x08174630 in zif_mysql_query ()
#7  0x08113a5a in zend_do_fcall_common_helper ()
#8  0x08114091 in zend_do_fcall_handler ()
#9  0x080fc375 in execute ()
#10 0x08113b42 in zend_do_fcall_common_helper ()
#11 0x08113e99 in zend_do_fcall_by_name_handler ()
#12 0x080fc375 in execute ()
#13 0x08113b42 in zend_do_fcall_common_helper ()
#14 0x08113e99 in zend_do_fcall_by_name_handler ()
#15 0x080fc375 in execute ()
#16 0x08113b42 in zend_do_fcall_common_helper ()
#17 0x08113e99 in zend_do_fcall_by_name_handler ()
#18 0x080fc375 in execute ()
#19 0x08113b42 in zend_do_fcall_common_helper ()
#20 0x08113e99 in zend_do_fcall_by_name_handler ()
#21 0x080fc375 in execute ()
#22 0x08113b42 in zend_do_fcall_common_helper ()
---Type return to continue, or q return to quit---
#23 0x08113e99 in zend_do_fcall_by_name_handler ()
#24 0x080fc375 in execute ()
#25 0x08113b42 in zend_do_fcall_common_helper ()
#26 0x08113e99 in zend_do_fcall_by_name_handler ()
#27 0x080fc375 in execute ()
#28 0x08113b42 in zend_do_fcall_common_helper ()
#29 0x08113e99 in zend_do_fcall_by_name_handler ()
#30 0x080fc375 in execute ()
#31 0x08113b42 in zend_do_fcall_common_helper ()
#32 0x08113e99 in zend_do_fcall_by_name_handler ()
#33 0x080fc375 in execute ()
#34 0x08113b42 in zend_do_fcall_common_helper ()
#35 0x08113e99 in zend_do_fcall_by_name_handler ()
#36 0x080fc375 in execute ()
#37 0x08118cd6 in zend_include_or_eval_handler ()
#38 0x080fc375 in execute ()
#39 0x08113b42 in zend_do_fcall_common_helper ()
#40 0x08113e99 in zend_do_fcall_by_name_handler ()
#41 0x080fc375 in execute ()
#42 0x08118cd6 in zend_include_or_eval_handler ()
#43 0x080fc375 in execute ()
#44 0x08113b42 in zend_do_fcall_common_helper ()
#45 0x08113e99 in zend_do_fcall_by_name_handler ()
---Type return to continue, or q return to quit---
#46 0x080fc375 in execute ()
#47 0x08113b42 in zend_do_fcall_common_helper ()
#48 0x08113e99 in zend_do_fcall_by_name_handler ()
#49 0x080fc375 in execute ()
#50 0x08113b42 in zend_do_fcall_common_helper ()
#51 0x08113e99 in zend_do_fcall_by_name_handler ()
#52 0x080fc375 in execute ()
#53 0x08113b42 in zend_do_fcall_common_helper ()
#54 0x08113e99 in zend_do_fcall_by_name_handler ()
#55 0x080fc375 in execute ()
#56 0x080e1a68 in zend_execute_scripts ()
#57 0x080b98da 

#31324 [Opn-Bgs]: function strlen miscounts

2004-12-30 Thread rasmus
 ID:   31324
 Updated by:   [EMAIL PROTECTED]
 Reported By:  phpbug at tore dot cc
-Status:   Open
+Status:   Bogus
 Bug Type: Strings related
 Operating System: Solaris 10
 PHP Version:  5.0.2
 New Comment:

Did you read the documentation?

; overload(replace) single byte functions by mbstring functions.
; mail(), ereg(), etc are overloaded by mb_send_mail(), mb_ereg(),
; etc. Possible values are 0,1,2,4 or combination of them.
; For example, 7 for overload everything.
; 0: No overload
; 1: Overload mail() function
; 2: Overload str*() functions
; 4: Overload ereg*() functions
;mbstring.func_overload = 0


Previous Comments:


[2004-12-30 14:33:30] phpbug at tore dot cc

I have traced down the trouble.
When multibyte strings support is complied in to php the internal
function 'strlen' is aliased to the function 'mb_strlen'.
mb_strlen counts the number of characters in the binary string
depending of what default encoding is used.

I have set the default chars to UTF-8 and SJIS (japanese) on my sparc
machine. That is why I only see it there.

Please remove the aliasing between strlen and mb_strlen!



[2004-12-30 10:55:57] [EMAIL PROTECTED]

It's impossible to extract that code from PHP, and as we don't have
access to a solaris machine we can not really debug this.



[2004-12-29 23:22:50] phpbug at tore dot cc

Are 64bit processors not supported by php?
Which machine architecture is 'my system'?

The php is compiled with gcc2 AND gcc3. With solaris 9 AND solaris 10.
The same trouble occurs.
So I need to have the code for 'strlen' in php extracted before I can
figure out where the source for the trouble is.

A simple C-program using string.h's strlen cause no troule at all.



[2004-12-29 21:42:53] [EMAIL PROTECTED]

Sounds like either a compiler or libc bug. I cannot replicate this on
my systems either.



[2004-12-29 19:13:28] phpbug at tore dot cc

I might add that I tried php-5.0.3 on an intel-based solaris 10 machine
and there were no problems with the strlen.



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

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


#31353 [NEW]: stuuuu-piiiid :)))

2004-12-30 Thread not at your dot job
From: not at your dot job
Operating system: win
PHP version:  5.0.1
PHP Bug Type: Output Control
Bug description:  st-pd :)))

Description:

you're so cheeky motherphuck-R-zz

Reproduce code:
---
?php

echo testbr\n;

echo pass 1br\n;
// -blahblah?
echo pass 2br\n;

?
:

Expected result:

test
pass 1
pass 2
:

Actual result:
--
test
pass 1
echo pass 2br
\n;
:

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


#31353 [Opn-Bgs]: stuuuu-piiiid :)))

2004-12-30 Thread sniper
 ID:   31353
 Updated by:   [EMAIL PROTECTED]
 Reported By:  not at your dot job
-Status:   Open
+Status:   Bogus
 Bug Type: Output Control
 Operating System: win
 PHP Version:  5.0.1
 New Comment:

*sigh*



Previous Comments:


[2004-12-30 14:55:43] not at your dot job

Description:

you're so cheeky motherphuck-R-zz

Reproduce code:
---
?php

echo testbr\n;

echo pass 1br\n;
// -blahblah?
echo pass 2br\n;

?
:

Expected result:

test
pass 1
pass 2
:

Actual result:
--
test
pass 1
echo pass 2br
\n;
:





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


#31324 [Bgs-Csd]: function strlen miscounts

2004-12-30 Thread phpbug at tore dot cc
 ID:   31324
 User updated by:  phpbug at tore dot cc
 Reported By:  phpbug at tore dot cc
-Status:   Bogus
+Status:   Closed
 Bug Type: Strings related
 Operating System: Solaris 10
 PHP Version:  5.0.2
 New Comment:

I don't count 'php.ini' to documentation. Anyway thanks for the time.


Previous Comments:


[2004-12-30 14:44:56] [EMAIL PROTECTED]

Did you read the documentation?

; overload(replace) single byte functions by mbstring functions.
; mail(), ereg(), etc are overloaded by mb_send_mail(), mb_ereg(),
; etc. Possible values are 0,1,2,4 or combination of them.
; For example, 7 for overload everything.
; 0: No overload
; 1: Overload mail() function
; 2: Overload str*() functions
; 4: Overload ereg*() functions
;mbstring.func_overload = 0



[2004-12-30 14:33:30] phpbug at tore dot cc

I have traced down the trouble.
When multibyte strings support is complied in to php the internal
function 'strlen' is aliased to the function 'mb_strlen'.
mb_strlen counts the number of characters in the binary string
depending of what default encoding is used.

I have set the default chars to UTF-8 and SJIS (japanese) on my sparc
machine. That is why I only see it there.

Please remove the aliasing between strlen and mb_strlen!



[2004-12-30 10:55:57] [EMAIL PROTECTED]

It's impossible to extract that code from PHP, and as we don't have
access to a solaris machine we can not really debug this.



[2004-12-29 23:22:50] phpbug at tore dot cc

Are 64bit processors not supported by php?
Which machine architecture is 'my system'?

The php is compiled with gcc2 AND gcc3. With solaris 9 AND solaris 10.
The same trouble occurs.
So I need to have the code for 'strlen' in php extracted before I can
figure out where the source for the trouble is.

A simple C-program using string.h's strlen cause no troule at all.



[2004-12-29 21:42:53] [EMAIL PROTECTED]

Sounds like either a compiler or libc bug. I cannot replicate this on
my systems either.



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

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


#29104 [Com]: Function declaration in method doesn't work

2004-12-30 Thread ulderico at maber dot com dot br
 ID:   29104
 Comment by:   ulderico at maber dot com dot br
 Reported By:  tomas_matousek at hotmail dot com
 Status:   Open
 Bug Type: Zend Engine 2 problem
 Operating System: *
 PHP Version:  5.0.0
 Assigned To:  Andi
 New Comment:

IMHO, Nested Functions are BADWRONG, thus they should be disabled. 

Firstly, when you DECLARE a function inside a function, you have a
redeclaration problem. Try to execute the parent function twice and
most likely you'll receive a message: Fatal error:  Cannot redeclare
. 

OK! Some may dispute: let's create an undeclare_function() so as to
allow at the end of the function undeclare the child function. It would
enable to reinvoke the parent function whenever we like. Well, THIS IS
ALSO BR. Why would you undeclare a function that you're going to use?

Secondly, if a function needs to work in a closed (encapsuled)
environment, well, I think you need a CLASS, not a function. In a class
you may have a public, private or protected variables invoked by either
public, private or protected methods.

Thusly, a code like this (sorry the indentation, I want to save
space):
class A
{ 
  function b(){}
  function c(){}
  function d(){}
  function g(){ 
echo function g - begin\n;
function f(){echo function f\n;} 
echo function g - end\n;
  }
}

should be written like this:
class A
{ 
  function b(){}
  function c(){}
  function d(){}
  function g(){ 
echo function g - begin\n;
f::f();
echo function g - end\n;
  }
}
class f{
function f(){echo function f\n;} 
}

$obj = new A();
$obj-g();

So, the rationale is, why you need to have function within function if
you've got classes?


Previous Comments:


[2004-08-14 01:24:12] [EMAIL PROTECTED]

While nested functions are maybe useful feature for someone declaration
of a function inside the body of a method (which happens to be a
function inside a class) is _ambigious_ . Why? There is no reserved
word method for marking methods of a class and function is used so
when it is between {} after class name function creates a method of
the class. IMO function inside a method should not be possible.



[2004-07-16 18:00:35] postings-php-bug at hans-spath dot de

Wait a minute, PHP doesn't support nested functions?

Holy shit, documentation lies!

http://www.php.net/manual/en/language.functions.php
Example 12-3. Functions within functions

Do we need to file a documentation bug, too?



[2004-07-13 21:46:59] [EMAIL PROTECTED]

PHP does not support nested functions. Still we need to disable this.



[2004-07-13 21:42:52] tomas_matousek at hotmail dot com

PHP supports declaring functions inline, i.e. almost anywhere in a
code. Such function is declared as global wherever it is declared.
Hence, I don't see any ambiguity if a function is declared inside a
method. PHP doesn't support adding new methods into existing class.
That's why a function declared in method can only be a global one.



[2004-07-13 17:45:57] Jason at hybd dot net

From what I gather, like most languages, PHP doesn't 
support 'nested' methods. (And therefore I doubt this is 
a bug)

Where you are calling f() is ambigous. As far as PHP is 
concerned f() is probably a global function and not a 
method embedded inside a::g().



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

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


#29104 [Com]: Function declaration in method doesn't work

2004-12-30 Thread ulderico at maber dot com dot br
 ID:   29104
 Comment by:   ulderico at maber dot com dot br
 Reported By:  tomas_matousek at hotmail dot com
 Status:   Open
 Bug Type: Zend Engine 2 problem
 Operating System: *
 PHP Version:  5.0.0
 Assigned To:  Andi
 New Comment:

OH! In time! Just to reinforce the first and the second paragraph of my
last comment.

Why would you create a function that should be invoked JUST ONCE?
Initialize environment? It makes no point. You can do it directly in
the code, using if to distinguish any situation of environment that
one may have.


Previous Comments:


[2004-12-30 15:16:42] ulderico at maber dot com dot br

IMHO, Nested Functions are BADWRONG, thus they should be disabled. 

Firstly, when you DECLARE a function inside a function, you have a
redeclaration problem. Try to execute the parent function twice and
most likely you'll receive a message: Fatal error:  Cannot redeclare
. 

OK! Some may dispute: let's create an undeclare_function() so as to
allow at the end of the function undeclare the child function. It would
enable to reinvoke the parent function whenever we like. Well, THIS IS
ALSO BR. Why would you undeclare a function that you're going to use?

Secondly, if a function needs to work in a closed (encapsuled)
environment, well, I think you need a CLASS, not a function. In a class
you may have a public, private or protected variables invoked by either
public, private or protected methods.

Thusly, a code like this (sorry the indentation, I want to save
space):
class A
{ 
  function b(){}
  function c(){}
  function d(){}
  function g(){ 
echo function g - begin\n;
function f(){echo function f\n;} 
echo function g - end\n;
  }
}

should be written like this:
class A
{ 
  function b(){}
  function c(){}
  function d(){}
  function g(){ 
echo function g - begin\n;
f::f();
echo function g - end\n;
  }
}
class f{
function f(){echo function f\n;} 
}

$obj = new A();
$obj-g();

So, the rationale is, why you need to have function within function if
you've got classes?



[2004-08-14 01:24:12] [EMAIL PROTECTED]

While nested functions are maybe useful feature for someone declaration
of a function inside the body of a method (which happens to be a
function inside a class) is _ambigious_ . Why? There is no reserved
word method for marking methods of a class and function is used so
when it is between {} after class name function creates a method of
the class. IMO function inside a method should not be possible.



[2004-07-16 18:00:35] postings-php-bug at hans-spath dot de

Wait a minute, PHP doesn't support nested functions?

Holy shit, documentation lies!

http://www.php.net/manual/en/language.functions.php
Example 12-3. Functions within functions

Do we need to file a documentation bug, too?



[2004-07-13 21:46:59] [EMAIL PROTECTED]

PHP does not support nested functions. Still we need to disable this.



[2004-07-13 21:42:52] tomas_matousek at hotmail dot com

PHP supports declaring functions inline, i.e. almost anywhere in a
code. Such function is declared as global wherever it is declared.
Hence, I don't see any ambiguity if a function is declared inside a
method. PHP doesn't support adding new methods into existing class.
That's why a function declared in method can only be a global one.



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

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


#31324 [Csd-Bgs]: function strlen miscounts

2004-12-30 Thread rasmus
 ID:   31324
 Updated by:   [EMAIL PROTECTED]
 Reported By:  phpbug at tore dot cc
-Status:   Closed
+Status:   Bogus
 Bug Type: Strings related
 Operating System: Solaris 10
 PHP Version:  5.0.2
 New Comment:

There is no bug here, hence the bogus status.

Here is the reference in the docs linked from php.net/mbstring:

http://php.net/manual/en/ref.mbstring.php#mbstring.overload

Does that count as documentation?


Previous Comments:


[2004-12-30 14:53:59] phpbug at tore dot cc

I don't count 'php.ini' to documentation. Anyway thanks for the time.



[2004-12-30 14:44:56] [EMAIL PROTECTED]

Did you read the documentation?

; overload(replace) single byte functions by mbstring functions.
; mail(), ereg(), etc are overloaded by mb_send_mail(), mb_ereg(),
; etc. Possible values are 0,1,2,4 or combination of them.
; For example, 7 for overload everything.
; 0: No overload
; 1: Overload mail() function
; 2: Overload str*() functions
; 4: Overload ereg*() functions
;mbstring.func_overload = 0



[2004-12-30 14:33:30] phpbug at tore dot cc

I have traced down the trouble.
When multibyte strings support is complied in to php the internal
function 'strlen' is aliased to the function 'mb_strlen'.
mb_strlen counts the number of characters in the binary string
depending of what default encoding is used.

I have set the default chars to UTF-8 and SJIS (japanese) on my sparc
machine. That is why I only see it there.

Please remove the aliasing between strlen and mb_strlen!



[2004-12-30 10:55:57] [EMAIL PROTECTED]

It's impossible to extract that code from PHP, and as we don't have
access to a solaris machine we can not really debug this.



[2004-12-29 23:22:50] phpbug at tore dot cc

Are 64bit processors not supported by php?
Which machine architecture is 'my system'?

The php is compiled with gcc2 AND gcc3. With solaris 9 AND solaris 10.
The same trouble occurs.
So I need to have the code for 'strlen' in php extracted before I can
figure out where the source for the trouble is.

A simple C-program using string.h's strlen cause no troule at all.



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

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


#21802 [NoF-Csd]: unexpected T_WHITESPACE

2004-12-30 Thread sniper
 ID:   21802
 Updated by:   [EMAIL PROTECTED]
 Reported By:  gmourani at openna dot com
-Status:   No Feedback
+Status:   Closed
 Bug Type: Compile Failure
 Operating System: OpenNA Linux
 PHP Version:  4.3.0
 New Comment:

This bug has been fixed in CVS.

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




Previous Comments:


[2004-10-06 09:17:33] jpmarroquin at mail dot com

I'm getting the same error but with PHP 5.0.2!!!
This is on Mandrake 10.0, Apache 1.3.31



[2004-06-25 22:35:00] eggert at gnu dot org

Please see the patch in the PHP bug 28930 description. I think this
patch will fix bug 21802.



[2004-06-25 14:33:58] mandreiana at yahoo dot com

Fedora SRPM has this:

# bison-1.875-2 seems to produce a broken parser; workaround.
mkdir Zend  cp ../Zend/zend_{language,ini}_parser.[ch] Zend



[2004-03-31 02:09:52] monk at farpost dot com

Some error with php-4.3.5 and bison-1.875
Fixed by installing bison-1.35



[2003-07-10 04:26:05] [EMAIL PROTECTED]

Re-classified to the proper category



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

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


#28930 [Asn-Csd]: [PATCH] PHP sources pick wrong header files generated by bison

2004-12-30 Thread sniper
 ID:   28930
 Updated by:   [EMAIL PROTECTED]
 Reported By:  eggert at gnu dot org
-Status:   Assigned
+Status:   Closed
 Bug Type: Compile Failure
 Operating System: *
 PHP Version:  4CVS, 5CVS
 Assigned To:  sniper
 New Comment:

This bug has been fixed in CVS.

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




Previous Comments:


[2004-11-30 22:13:17] mej at eterm dot org

Tested this patch against 4.3.9.  It applies cleanly and does indeed
fix bug #21802.



[2004-07-08 12:15:55] [EMAIL PROTECTED]

Verified. (I misunderstood the problem first, sorry..)




[2004-06-25 22:33:22] eggert at gnu dot org

Description:

make install fails as described under actual result.
The problem is that the source files are picking up the wrong include
files: they should be including the new files generated by Bison 1.875,
but they are including the prebuilt files generated by Bison 1.35. Here
is a patch. This patch should fix PHP bug 21802.

diff -prU2 php-4.3.7/Zend/zend_compile.c
php-4.3.7-fix/Zend/zend_compile.c
--- php-4.3.7/Zend/zend_compile.c   2003-08-28 09:08:11 -0700
+++ php-4.3.7-fix/Zend/zend_compile.c   2004-06-25 13:11:23 -0700
@@ -19,5 +19,5 @@
 
 
-#include zend_language_parser.h
+#include zend_language_parser.h
 #include zend.h
 #include zend_compile.h
diff -prU2 php-4.3.7/Zend/zend_highlight.c
php-4.3.7-fix/Zend/zend_highlight.c
--- php-4.3.7/Zend/zend_highlight.c 2003-12-25 10:57:28 -0800
+++ php-4.3.7-fix/Zend/zend_highlight.c 2004-06-25 13:10:57 -0700
@@ -20,5 +20,5 @@
 
 #include zend.h
-#include zend_language_parser.h
+#include zend_language_parser.h
 #include zend_compile.h
 #include zend_highlight.h
diff -prU2 php-4.3.7/Zend/zend_indent.c
php-4.3.7-fix/Zend/zend_indent.c
--- php-4.3.7/Zend/zend_indent.c2002-12-31 08:23:03 -0800
+++ php-4.3.7-fix/Zend/zend_indent.c2004-06-25 13:11:02 -0700
@@ -23,5 +23,5 @@
 
 #include zend.h
-#include zend_language_parser.h
+#include zend_language_parser.h
 #include zend_compile.h
 #include zend_indent.h
diff -prU2 php-4.3.7/Zend/zend_ini_scanner.l
php-4.3.7-fix/Zend/zend_ini_scanner.l
--- php-4.3.7/Zend/zend_ini_scanner.l   2003-07-24 01:44:28 -0700
+++ php-4.3.7-fix/Zend/zend_ini_scanner.l   2004-06-25 13:10:34 -0700
@@ -31,5 +31,5 @@
 #include zend.h
 #include zend_globals.h
-#include zend_ini_parser.h
+#include zend_ini_parser.h
 #include zend_ini_scanner.h
 
diff -prU2 php-4.3.7/Zend/zend_language_scanner.l
php-4.3.7-fix/Zend/zend_language_scanner.l
--- php-4.3.7/Zend/zend_language_scanner.l  2004-02-03 06:31:19 -0800
+++ php-4.3.7-fix/Zend/zend_language_scanner.l  2004-06-25 13:11:16
-0700
@@ -48,5 +48,5 @@
 #include zend.h
 #include zend_alloc.h
-#include zend_language_parser.h
+#include zend_language_parser.h
 #include zend_compile.h
 #include zend_language_scanner.h


Reproduce code:
---
To reproduce the problem, install Bison 1.875 and
build PHP 4.3.7 with the following commands:

mkdir obj
cd obj
sh ../php-4.3.7/configure
make
make install

Expected result:

Expected a clean make install.

Actual result:
--
$ make install
Installing PHP SAPI module:   cgi
Installing PHP CGI into: /tmp/prefix/bin/
Installing PEAR environment:  /tmp/prefix/lib/php/

Parse error: syntax error, unexpected T_WHITESPACE in
/home/eggert/src/php/php-4.3.7/pear/install-pear.php on line 3
make[1]: *** [install-pear-installer] Error 255
make: *** [install-pear] Error 2






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


#31355 [NEW]: Access Violation at 00BA73CD

2004-12-30 Thread najones3 at vt dot edu
From: najones3 at vt dot edu
Operating system: Windows XP
PHP version:  5.0.1
PHP Bug Type: Scripting Engine problem
Bug description:  Access Violation at 00BA73CD

Description:

I recently moved from an apache webserver to IIS just because there were
some conflicts.  The php code works fine but now on all my .php pages
there is a generated piece of code at the bottom stating that php has
encountered an access violation at X.  It was not producing this
while running on apache, but i have followed all steps for setting it up
on IIS.  Please help me get rid of this, it is driving me nuts


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


#31101 [Opn-Csd]: missing kerberos header file path with --with-openssl

2004-12-30 Thread sniper
 ID:   31101
 Updated by:   [EMAIL PROTECTED]
 Reported By:  phpbr at ecartz dot com
-Status:   Open
+Status:   Closed
 Bug Type: OpenSSL related
 Operating System: *
 PHP Version:  4CVS, 5CVS (2004-12-23)
 Assigned To:  sniper
 New Comment:

This bug has been fixed in CVS.

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




Previous Comments:


[2004-12-30 08:12:22] phpbr at ecartz dot com

# pkg-config --cflags-only-I openssl
pkg-config: command not found

Installing pkg-config does in fact fix this and allows compile. 
Comparing the old config.cache file with the current config.cache file,
I see that it did in fact note that pkg-config was not there.  However,
it did not throw an error on not having pkg-config, just a comment
pkg-config: no.

I see three things that I would call workarounds:

1.  Install pkg-config, which handles the openssl requirements for you.
 

2.  Manually exporting CPPFLAGS with the appropriate -I (or manually
edit the makefile, but the export is probably better).

3.  Configure with --with-imap --with-kerberos, which will add the
appropriate -I for you.  

I see two ways (there may be more) to implement solutions that avoid
the workarounds above:

1.  In the configure script, move the code that handles --with-kerberos
outside of the code that handles --with-imap.  Currently, combining the
two will produce the required -I, so moving the code outside
--with-imap should make it work.

2.  Throw an error when --with-openssl is used and pkg-config is not
available.  If pkg-config is required to properly compile
--with-openssl, then it should say so rather than waiting to throw an
obscure compile error during make.  Ideally, the error should be
overrideable, since pkg-config can be bypassed (see the three
workarounds above).

2 might be needed to handle other situations where openssl relies on
pkg-config to produce the correct library and header flags.  Further, 1
won't work with just --with-openssl but 2 will (tested).  Note that two
still requires workaround #1 (install pkg-config) when encountered. 
The difference is that it tells the user that.

Note:  as I have finished the install, I will no longer have access to
this server (which won't throw the error now anyway) and will be unable
to follow up with more testing.  You should be able to duplicate my
previous situation with a 

cd PKG_CONFIG_DIR; mv pkg-config pkg-config-unavailable

for any followups you might need to do.



[2004-12-30 04:50:48] [EMAIL PROTECTED]

If you have openssl properly installed (if via some rpm, also the
-devel rpm installed!) you should have it in pkg-config. What do these
commands output for you:

# pkg-config --libs openssl

and

pkg-config --cflags-only-I openssl




[2004-12-23 08:38:28] phpbr at ecartz dot com

Red Hat has suggested configure.in (may need to be
ext/openssl/config0.m4 in your case) script changes for this at
https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=82369

Note:  if you want to duplicate this, you would first need to compile
OpenSSL with Kerberos support.  

In the meantime, for anyone else who might encounter this problem, the
indicated work around seems to be to run 

export CPPFLAGS=$CPPFLAGS -I/usr/kerberos/include

before running make (at least the first time; if you run make multiple
times, it should still be there; you can check with 

echo $CPPFLAGS

; it should return something that contains -I/usr/kerberos/include).



[2004-12-23 08:37:48] phpbr at ecartz dot com

I took it another step down to 

./configure --with-openssl
make clean  make

and still get the same error (even without the --with-kerberos).  

I read http://us4.php.net/function.fsockopen to indicate that
--with-openssl is needed for full functionality of fsockopen in PHP
4.3.  At least that's what I'm guessing if you have compiled in
OpenSSL support means.

It seems to me that the current configure script only checks kerberos
in relation to IMAP (the kerberos checking code is inside the IMAP
checking code).  However, OpenSSL also seems to require kerberos, at
least in my install.  For this reason, I would like it if the
--with-kerberos added the necessary -I/usr/kerberos/include regardless
of whether --with-imap is included.  I am not sure how many others
would be affected by this.



[2004-12-15 19:41:23] phpbr at ecartz dot com

Description:

I ran configure with --with-kerberos=/usr/kerberos which correctly

#31321 [Bgs]: an object given to a function as a param. by value(!) is passed by reference

2004-12-30 Thread i25506 at informatik dot fh-wuerzburg dot de
 ID:   31321
 User updated by:  i25506 at informatik dot fh-wuerzburg dot de
 Reported By:  i25506 at informatik dot fh-wuerzburg dot de
 Status:   Bogus
 Bug Type: *General Issues
 Operating System: Win32 and Linux
 PHP Version:  5.0.1
 New Comment:

O.K., I understand what You mean, since the new object-model in PHP5,
variables not holding the object itself, but a handle to the object. In
my understanding that is similar to a reference on a normal variable.
If I do '$a=$b;' on a normal variable $a holds a copy of $b.
'$a=$b;' get's $a a reference to $b. If I do '$a=$b;' where $b holding
a object-handle I don't get a copy of the object, I only get a copy of
the handle - but what is in that meening '$a=$b'?. This is in my eyes
very inconsistent.
The manual about 'function()' says 'function($a)' passes $a by value
and there is no hint to the new meaning on the PHP5 object-model, so I
made this mistake...


Previous Comments:


[2004-12-28 15:25:43] [EMAIL PROTECTED]

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

Also read the migration guide.



[2004-12-28 14:39:02] i25506 at informatik dot fh-wuerzburg dot de

Description:

If you try to give an object as parameter to a function by value, the
object is not copied but passed by reference. So if you change the
object in that function, you change your original object - after the
function is returned you get still the changed object.
Shortly said:
function($myObject) and function($myObject)
are the same thing, which is wrong. All PHP-versions 5 i've had before
(many 3.x and 4.x) does right.

Reproduce code:
---
?php
function Test_FunctionParameter($myobj)
{
  $myobj-testattribute=Changed!;
}

class TestClass
{
  var $testattribute;
}

$testobj1=new TestClass;

$testobj2=new stdClass;
?
html
head
title?php echo basename(__FILE__).-.phpversion();?/title
/head
body
h1?php echo basename(__FILE__).-.phpversion();?/h1
table border
tr
th/ththOriginal object:/ththObject after passing it by
value(!) to a function which changes the attribute:/th
/tr
tr
td1. Self defined class/td
tdprecode
?php
$testobj1-testattribute=3.14159265;
print_r($testobj1);
?
/code/pre/td
tdprecode
?php
Test_FunctionParameter($testobj1);
print_r($testobj1);
?
/code/pre/td
/tr
tr
td2. pre defined stdClass/td
tdprecode
?php
$testobj2-testattribute=array(1, 2, 3, 4);
print_r($testobj2);
?
/code/pre/td
tdprecode
?php
Test_FunctionParameter($testobj2);
print_r($testobj2);
?
/code/pre/td
/tr
/table
/body
/html

Expected result:

1. Self defined class 
Original object:
testclass Object
(
[testattribute] = 3.14159265
)

Object after passing it by value(!) to a function which changes the
attribute: 
testclass Object
(
[testattribute] = 3.14159265
)

 
2. pre defined stdClass 
Original object:
stdClass Object
(
[testattribute] = Array
(
[0] = 1
[1] = 2
[2] = 3
[3] = 4
)

)

Object after passing it by value(!) to a function which changes the
attribute: 
stdClass Object
(
[testattribute] = Array
(
[0] = 1
[1] = 2
[2] = 3
[3] = 4
)

)


Actual result:
--
1. Self defined class 
Original object:
testclass Object
(
[testattribute] = 3.14159265
)

Object after passing it by value(!) to a function which changes the
attribute: 
testclass Object
(
[testattribute] = Changed!
)

 
2. pre defined stdClass 
Original object:
stdClass Object
(
[testattribute] = Array
(
[0] = 1
[1] = 2
[2] = 3
[3] = 4
)

)

Object after passing it by value(!) to a function which changes the
attribute: 
stdClass Object
(
[testattribute] = Changed!
)






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


#31356 [NEW]: Serializing StdClass objects causes segfault

2004-12-30 Thread [EMAIL PROTECTED]
From: [EMAIL PROTECTED]
Operating system: Windows XP SP-2
PHP version:  5CVS-2004-12-30 (dev)
PHP Bug Type: Reproducible crash
Bug description:  Serializing StdClass objects causes segfault

Description:

Serializing StdClass objects causes segfault in PHP_5_0 but not in HEAD.

zend_std_get_method() (third stackframe) is called with __sleep as the
value for the method_name parameter so it looks like the serializer tries
to call a non-existant __sleep() method on the object.

Reproduce code:
---
?php
print serialize(new StdClass);
?


Expected result:

HEAD: O:8:stdClass:0:{}

Actual result:
--
PHP_5_0:

php5ts_debug.dll!zend_object_store_get_object(_zval_struct *
zobject=0x0001, void * * * tsrm_ls=0x00902c48)  Line 200 + 0x3  C
php5ts_debug.dll!zend_objects_get_address(_zval_struct *
zobject=0x0001, void * * * tsrm_ls=0x00902c48)  Line 111 + 0xd  C
php5ts_debug.dll!zend_std_get_method(_zval_struct * *
object_ptr=0x00a31d50, char * method_name=0x1058f1c8, int method_len=7,
void * * * tsrm_ls=0x00902c48)  Line 680 + 0xd  C
php5ts_debug.dll!zend_call_function(_zend_fcall_info * fci=0x0012ecc8,
_zend_fcall_info_cache * fci_cache=0x, void * * *
tsrm_ls=0x00902c48)  Line 688 + 0x30C
php5ts_debug.dll!call_user_function_ex(_hashtable *
function_table=0x00908d40, _zval_struct * * object_pp=0x00a214e4,
_zval_struct * function_name=0x0012ef60, _zval_struct * *
retval_ptr_ptr=0x0012ef78, unsigned int param_count=0, _zval_struct * * *
params=0x, int no_separation=1, _hashtable *
symbol_table=0x, void * * * tsrm_ls=0x00902c48)  Line 551 + 0xf C
php5ts_debug.dll!php_var_serialize_intern(smart_str * buf=0x0012f3b0,
_zval_struct * * struc=0x00a214e4, _hashtable * var_hash=0x0012f3c4, void
* * * tsrm_ls=0x00902c48)  Line 678 + 0x38  C
php5ts_debug.dll!php_var_serialize(smart_str * buf=0x0012f3b0,
_zval_struct * * struc=0x00a214e4, _hashtable * var_hash=0x0012f3c4, void
* * * tsrm_ls=0x00902c48)  Line 771 + 0x15  C
php5ts_debug.dll!zif_serialize(int ht=1, _zval_struct *
return_value=0x00a31de0, _zval_struct * this_ptr=0x, int
return_value_used=1, void * * * tsrm_ls=0x00902c48)  Line 794 + 0x15C
php5ts_debug.dll!zend_do_fcall_common_helper(_zend_execute_data *
execute_data=0x0012f744, _zend_op * opline=0x00a31a88, _zend_op_array *
op_array=0x00a31680, void * * * tsrm_ls=0x00902c48)  Line 2711 + 0x32   C
php5ts_debug.dll!zend_do_fcall_handler(_zend_execute_data *
execute_data=0x0012f744, _zend_op * opline=0x00a31a88, _zend_op_array *
op_array=0x00a31680, void * * * tsrm_ls=0x00902c48)  Line 2843 + 0x15   C
php5ts_debug.dll!execute(_zend_op_array * op_array=0x00a31680, void * * *
tsrm_ls=0x00902c48)  Line 1400 + 0x17   C
php5ts_debug.dll!zend_execute_scripts(int type=8, void * * *
tsrm_ls=0x00902c48, _zval_struct * * retval=0x, int file_count=3,
...)  Line 1060 + 0x21  C
php5ts_debug.dll!php_execute_script(_zend_file_handle *
primary_file=0x0012ff2c, void * * * tsrm_ls=0x00902c48)  Line 1628 +
0x1bC
php.exe!main(int argc=2, char * * argv=0x00904c68)  Line 943 + 0x13 C
php.exe!mainCRTStartup()  Line 398 + 0x11   C
kernel32.dll!7c816d4f()
kernel32.dll!7c8399f3()

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


#31356 [Opn-Ver]: Serializing StdClass objects causes segfault

2004-12-30 Thread sebastian
 ID:   31356
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Open
+Status:   Verified
 Bug Type: Reproducible crash
 Operating System: Windows XP SP-2
 PHP Version:  5CVS-2004-12-30 (dev)


Previous Comments:


[2004-12-30 16:58:17] [EMAIL PROTECTED]

Description:

Serializing StdClass objects causes segfault in PHP_5_0 but not in
HEAD.

zend_std_get_method() (third stackframe) is called with __sleep as the
value for the method_name parameter so it looks like the serializer
tries to call a non-existant __sleep() method on the object.

Reproduce code:
---
?php
print serialize(new StdClass);
?


Expected result:

HEAD: O:8:stdClass:0:{}

Actual result:
--
PHP_5_0:

php5ts_debug.dll!zend_object_store_get_object(_zval_struct *
zobject=0x0001, void * * * tsrm_ls=0x00902c48)  Line 200 + 0x3  C
php5ts_debug.dll!zend_objects_get_address(_zval_struct *
zobject=0x0001, void * * * tsrm_ls=0x00902c48)  Line 111 + 0xd  C
php5ts_debug.dll!zend_std_get_method(_zval_struct * *
object_ptr=0x00a31d50, char * method_name=0x1058f1c8, int method_len=7,
void * * * tsrm_ls=0x00902c48)  Line 680 + 0xd  C
php5ts_debug.dll!zend_call_function(_zend_fcall_info * fci=0x0012ecc8,
_zend_fcall_info_cache * fci_cache=0x, void * * *
tsrm_ls=0x00902c48)  Line 688 + 0x30C
php5ts_debug.dll!call_user_function_ex(_hashtable *
function_table=0x00908d40, _zval_struct * * object_pp=0x00a214e4,
_zval_struct * function_name=0x0012ef60, _zval_struct * *
retval_ptr_ptr=0x0012ef78, unsigned int param_count=0, _zval_struct * *
* params=0x, int no_separation=1, _hashtable *
symbol_table=0x, void * * * tsrm_ls=0x00902c48)  Line 551 +
0xf C
php5ts_debug.dll!php_var_serialize_intern(smart_str * buf=0x0012f3b0,
_zval_struct * * struc=0x00a214e4, _hashtable * var_hash=0x0012f3c4,
void * * * tsrm_ls=0x00902c48)  Line 678 + 0x38 C
php5ts_debug.dll!php_var_serialize(smart_str * buf=0x0012f3b0,
_zval_struct * * struc=0x00a214e4, _hashtable * var_hash=0x0012f3c4,
void * * * tsrm_ls=0x00902c48)  Line 771 + 0x15 C
php5ts_debug.dll!zif_serialize(int ht=1, _zval_struct *
return_value=0x00a31de0, _zval_struct * this_ptr=0x, int
return_value_used=1, void * * * tsrm_ls=0x00902c48)  Line 794 + 0x15C
php5ts_debug.dll!zend_do_fcall_common_helper(_zend_execute_data *
execute_data=0x0012f744, _zend_op * opline=0x00a31a88, _zend_op_array *
op_array=0x00a31680, void * * * tsrm_ls=0x00902c48)  Line 2711 + 0x32   C
php5ts_debug.dll!zend_do_fcall_handler(_zend_execute_data *
execute_data=0x0012f744, _zend_op * opline=0x00a31a88, _zend_op_array *
op_array=0x00a31680, void * * * tsrm_ls=0x00902c48)  Line 2843 + 0x15   C
php5ts_debug.dll!execute(_zend_op_array * op_array=0x00a31680, void * *
* tsrm_ls=0x00902c48)  Line 1400 + 0x17 C
php5ts_debug.dll!zend_execute_scripts(int type=8, void * * *
tsrm_ls=0x00902c48, _zval_struct * * retval=0x, int
file_count=3, ...)  Line 1060 + 0x21C
php5ts_debug.dll!php_execute_script(_zend_file_handle *
primary_file=0x0012ff2c, void * * * tsrm_ls=0x00902c48)  Line 1628 +
0x1bC
php.exe!main(int argc=2, char * * argv=0x00904c68)  Line 943 + 0x13 C
php.exe!mainCRTStartup()  Line 398 + 0x11   C
kernel32.dll!7c816d4f()
kernel32.dll!7c8399f3()





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


#29180 [Opn]: Client crash

2004-12-30 Thread tila at home dot nl
 ID:   29180
 User updated by:  tila at home dot nl
 Reported By:  tila at home dot nl
 Status:   Open
 Bug Type: PostgreSQL related
 Operating System: Linux 2.4.24
 PHP Version:  5.0.4-pre
 New Comment:

When I add a line in the script so that it reads:

?php
$db = pg_connect(host=localhost user=apache password=apache
dbname=groupware);$QUERY = SELECT o.* FROM personoverview o;
$result = pg_exec($QUERY);
$total = pg_numrows($result);
$offset = $_GET['id']?$_GET['id']:0;
$temp_offset = $offset
$perpage = 10;
 
for ($i = $offset; (($i  $total)  ($i  ($offset + $perpage)));
$i++)
{
  $row = pg_fetch_row($result, $i);
}
 
echo $offset;
?

The result will display 5. Strange


Previous Comments:


[2004-12-29 23:54:25] tila at home dot nl

php5-STABLE-200412231730

tried this one, it still returns 42, can I do something else to help
you solve it, with some debugger or so?



[2004-12-29 21:27:44] [EMAIL PROTECTED]

Mark it as waiting for feedback until you have additional info.



[2004-12-29 20:42:11] tila at home dot nl

I have been away for some time, So still have to try, will let you know
if it works now. The 5.0.3 version still have some problems with it.



[2004-12-29 18:32:17] [EMAIL PROTECTED]

No feedback was provided. The bug is being suspended because
we assume that you are no longer experiencing the problem.
If this is not the case and you are able to provide the
information that was requested earlier, please do so and
change the status of the bug back to Open. Thank you.





[2004-12-22 09:19:41] [EMAIL PROTECTED]

Please try using this CVS snapshot:

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





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

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


#31344 [Fbk-Opn]: PHP 4.3.10 crashed Apache without message

2004-12-30 Thread sysadmin at amhosting dot com
 ID:   31344
 User updated by:  sysadmin at amhosting dot com
 Reported By:  sysadmin at amhosting dot com
-Status:   Feedback
+Status:   Open
 Bug Type: Apache2 related
 Operating System: Red Hat 9 + Legacy
 PHP Version:  4.3.10
 New Comment:

The example script, run in the bash shell, looks something like this
for Red Hat 9:

---start of script---
#!/bin/bash
service httpd start
sleep 3
ps ax | grep httpd
---end of script---

What I expect is to see a number of processes with the name httpd
with PID numbers, all different.

Before PHP install, I get that.

After PHP install, I get grep httpd

Remove PHP from the system, it works again.

Script enough for you?


Previous Comments:


[2004-12-30 13:39:01] [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 ?php and ends 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 avoid embedding huge scripts into the report.





[2004-12-30 13:22:50] egor at ensita dot net

the latest stable doesn't help. :(



[2004-12-30 08:10:14] [EMAIL PROTECTED]

Please try using this CVS snapshot:

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





[2004-12-30 07:51:26] sysadmin at amhosting dot com

Description:

In trying to upgrade my Plesk servers, I have found that one upgrade
worked, the rest bombed out.  To reduce the number of variables, I
built a Red Hat 9 server from CDs, installed Yum, ran a full upgrade
cycle, then tried to install 4.3.10.  Apache would not start, or would
crash immediately without any tombstones.

Reproduce code:
---
Load Red Hat 9 from CDs.
Install Yum per instructions from Fedora Legacy project
yum update
download php source.
./configure parameters
make
make install

Expected result:

I expected PHP 4.3.10 to install and run normally.

Actual result:
--
Apache died without a trace.  service httpd status said that the
service was dead but a PID file was in place.





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


#31290 [Com]: Syntax error reported in /usr/include/rpc/rpc_msg.h

2004-12-30 Thread will at internet-search-engines-faq dot com
 ID:   31290
 Comment by:   will at internet-search-engines-faq dot com
 Reported By:  will dot spencer at internet-search-engines-faq
 Status:   Feedback
 Bug Type: Compile Failure
 Operating System: FreeBSD 4.10-BETA #6
 PHP Version:  4.3.10
 New Comment:

I have done a cvsup to RELENG_5, and rebuilt both the world and the
kernel.

I am now running kernel 5.3-STABLE.

I receive the same general error when I make php4.3.10, but with a
slightly different error message:


In file included from /usr/include/rpc/rpc.h:59,
 from /usr/include/crypt.h:9,
 from /root/php-4.3.10/ext/standard/crypt.c:31:
/usr/include/rpc/rpc_msg.h:66: error: syntax error before numeric
constant
*** Error code 1


Previous Comments:


[2004-12-30 06:44:56] [EMAIL PROTECTED]

First try rebuilding the world.




[2004-12-25 01:04:15] will dot spencer at internet-search-engines-faq

Description:

I am experiencing something similar to bug report #6713, except with
php 4.3.10.

I cannot see an issue with FreeBSD's /usr/include/rpc/rpc_msg.h, which
has remained unchanged since 1999/08/27.

I see the same results when I use ./configure with no options or when I
use ./configure with the entire set of desired options.



Reproduce code:
---
rpc_msg.h lines 53-70 are:

enum msg_type {
CALL=0,
REPLY=1
};

enum reply_stat {
MSG_ACCEPTED=0,
MSG_DENIED=1
};

enum accept_stat {
SUCCESS=0,
PROG_UNAVAIL=1,
PROG_MISMATCH=2,
PROC_UNAVAIL=3,
GARBAGE_ARGS=4,
SYSTEM_ERR=5
};


Expected result:

I was hoping that 4.3.10 would make with no warnings or errors.  :)

Actual result:
--
# make
/bin/sh /root/php-4.3.10/libtool --silent --preserve-dup-deps
--mode=compile gcc  -Iext/standard/ -I/root/php-4.3.10/ext/standard/
-DPHP_ATOM_INC -I/root/php-4.3.10/include -I/root/php-4.3.10/main
-I/root/php-4.3.10 -I/root/php-4.3.10/Zend -I/usr/local/include/mysql
-I/usr/local/include  -I/root/php-4.3.10/TSRM  -g -O2  -prefer-pic -c
/root/php-4.3.10/ext/standard/crypt.c -o ext/standard/crypt.lo
In file included from /usr/include/rpc/rpc.h:56,
 from /usr/include/crypt.h:9,
 from /root/php-4.3.10/ext/standard/crypt.c:31:
/usr/include/rpc/rpc_msg.h:64: syntax error before `0'
*** Error code 1






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


#31356 [Ver-Fbk]: Serializing StdClass objects causes segfault

2004-12-30 Thread wez
 ID:   31356
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Verified
+Status:   Feedback
 Bug Type: Reproducible crash
 Operating System: Windows XP SP-2
 PHP Version:  5CVS-2004-12-30 (dev)
 New Comment:

Are you sure that you have a clean build?


Previous Comments:


[2004-12-30 16:58:17] [EMAIL PROTECTED]

Description:

Serializing StdClass objects causes segfault in PHP_5_0 but not in
HEAD.

zend_std_get_method() (third stackframe) is called with __sleep as the
value for the method_name parameter so it looks like the serializer
tries to call a non-existant __sleep() method on the object.

Reproduce code:
---
?php
print serialize(new StdClass);
?


Expected result:

HEAD: O:8:stdClass:0:{}

Actual result:
--
PHP_5_0:

php5ts_debug.dll!zend_object_store_get_object(_zval_struct *
zobject=0x0001, void * * * tsrm_ls=0x00902c48)  Line 200 + 0x3  C
php5ts_debug.dll!zend_objects_get_address(_zval_struct *
zobject=0x0001, void * * * tsrm_ls=0x00902c48)  Line 111 + 0xd  C
php5ts_debug.dll!zend_std_get_method(_zval_struct * *
object_ptr=0x00a31d50, char * method_name=0x1058f1c8, int method_len=7,
void * * * tsrm_ls=0x00902c48)  Line 680 + 0xd  C
php5ts_debug.dll!zend_call_function(_zend_fcall_info * fci=0x0012ecc8,
_zend_fcall_info_cache * fci_cache=0x, void * * *
tsrm_ls=0x00902c48)  Line 688 + 0x30C
php5ts_debug.dll!call_user_function_ex(_hashtable *
function_table=0x00908d40, _zval_struct * * object_pp=0x00a214e4,
_zval_struct * function_name=0x0012ef60, _zval_struct * *
retval_ptr_ptr=0x0012ef78, unsigned int param_count=0, _zval_struct * *
* params=0x, int no_separation=1, _hashtable *
symbol_table=0x, void * * * tsrm_ls=0x00902c48)  Line 551 +
0xf C
php5ts_debug.dll!php_var_serialize_intern(smart_str * buf=0x0012f3b0,
_zval_struct * * struc=0x00a214e4, _hashtable * var_hash=0x0012f3c4,
void * * * tsrm_ls=0x00902c48)  Line 678 + 0x38 C
php5ts_debug.dll!php_var_serialize(smart_str * buf=0x0012f3b0,
_zval_struct * * struc=0x00a214e4, _hashtable * var_hash=0x0012f3c4,
void * * * tsrm_ls=0x00902c48)  Line 771 + 0x15 C
php5ts_debug.dll!zif_serialize(int ht=1, _zval_struct *
return_value=0x00a31de0, _zval_struct * this_ptr=0x, int
return_value_used=1, void * * * tsrm_ls=0x00902c48)  Line 794 + 0x15C
php5ts_debug.dll!zend_do_fcall_common_helper(_zend_execute_data *
execute_data=0x0012f744, _zend_op * opline=0x00a31a88, _zend_op_array *
op_array=0x00a31680, void * * * tsrm_ls=0x00902c48)  Line 2711 + 0x32   C
php5ts_debug.dll!zend_do_fcall_handler(_zend_execute_data *
execute_data=0x0012f744, _zend_op * opline=0x00a31a88, _zend_op_array *
op_array=0x00a31680, void * * * tsrm_ls=0x00902c48)  Line 2843 + 0x15   C
php5ts_debug.dll!execute(_zend_op_array * op_array=0x00a31680, void * *
* tsrm_ls=0x00902c48)  Line 1400 + 0x17 C
php5ts_debug.dll!zend_execute_scripts(int type=8, void * * *
tsrm_ls=0x00902c48, _zval_struct * * retval=0x, int
file_count=3, ...)  Line 1060 + 0x21C
php5ts_debug.dll!php_execute_script(_zend_file_handle *
primary_file=0x0012ff2c, void * * * tsrm_ls=0x00902c48)  Line 1628 +
0x1bC
php.exe!main(int argc=2, char * * argv=0x00904c68)  Line 943 + 0x13 C
php.exe!mainCRTStartup()  Line 398 + 0x11   C
kernel32.dll!7c816d4f()
kernel32.dll!7c8399f3()





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


#31355 [Opn-Fbk]: Access Violation at 00BA73CD

2004-12-30 Thread derick
 ID:   31355
 Updated by:   [EMAIL PROTECTED]
 Reported By:  najones3 at vt dot edu
-Status:   Open
+Status:   Feedback
 Bug Type: Scripting Engine problem
 Operating System: Windows XP
 PHP Version:  5.0.1
 New Comment:

Not enough information was provided for us to be able
to handle this bug. Please re-read the instructions at
http://bugs.php.net/how-to-report.php

If you can provide more information, feel free to add it
to this bug and change the status back to Open.

Thank you for your interest in PHP.



Previous Comments:


[2004-12-30 16:08:33] najones3 at vt dot edu

Description:

I recently moved from an apache webserver to IIS just because there
were some conflicts.  The php code works fine but now on all my .php
pages there is a generated piece of code at the bottom stating that php
has encountered an access violation at X.  It was not producing
this while running on apache, but i have followed all steps for setting
it up on IIS.  Please help me get rid of this, it is driving me nuts






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


#31343 [Com]: Bug on Insert and Update with PHP 5.0.3

2004-12-30 Thread liang at saga-city dot com
 ID:   31343
 Comment by:   liang at saga-city dot com
 Reported By:  iam_simon at hotmail dot com
 Status:   Open
 Bug Type: MSSQL related
 Operating System: Windows 2000 with Apache 1.3.33
 PHP Version:  5.0.3
 New Comment:

We have the same problem, 
even after adding the include files. 
The error shows  SQL Execute failed ,
but it actually works and success.


Previous Comments:


[2004-12-30 05:31:23] iam_simon at hotmail dot com

You need to include() both of the following files from ADODB package:

adodb.inc.php
adodb-errorhandler.inc.php  

The variable $s in adodb-errorhandler.inc.php contains the error
message.



[2004-12-30 05:24:28] iam_simon at hotmail dot com

Description:

I have been using ADODB (a pouplar PHP database wrapper) for several
years and recently I upgraded to PHP 5.0.3 on Apache 1.3.33 with MSSQL.
I got tons error messages from log generated by
adodb-errorhandler.inc.php whenever my app uses INSERT or UPDATE to
the database. There is no problem with SELECT statement.

This is a problem with PHP 5.0.3 only,  5.0.2, 4.0.x or below doesn't
have this problem. 

I contacted author of ADODB, Mr. John Lim said it is a MSSQL/PHP bug,
so I am trying to report this bug here.

Although there is an error, but the row has successfully inserted into
the database.  I am using latest version of Adodb. 


Simon

Reproduce code:
---
$conn = ADONewConnection('mssql'); 
$conn-Connect(hostname, user, pass, dbname); 
$conn-Execute(INSERT INTO visitor_log(date_stamp, ip, host, agent)
Values('2004-12-29 07:10:52PM', '192.168.0.2', '', 'Mozilla/4.0
(compatible; MSIE 6.0; Windows NT 5.1; .NET CLR 1.1.4322)')); 
$conn-Close(); 

Expected result:

mssql error: [0: ] in EXECUTE(INSERT INTO visitor_log(date_stamp, ip,
host, agent) Values('2004-12-29 06:59:18PM', '192.168.0.2', '',
'Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET CLR
1.1.4322)'))

Actual result:
--
no error should be seen





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


#31356 [Fbk-Csd]: Serializing StdClass objects causes segfault

2004-12-30 Thread [EMAIL PROTECTED]
 ID:   31356
 User updated by:  [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Feedback
+Status:   Closed
 Bug Type: Reproducible crash
 Operating System: Windows XP SP-2
 PHP Version:  5CVS-2004-12-30 (dev)
 New Comment:

I made a clean checkout and rebuilt -- and not it works.

Below is the build script I use which I think should clean everything
before building:

cscript /nologo win32\build\cvsclean.js
rmdir /S /Q debug_ts
cscript /nologo win32\build\buildconf.js
cscript /nologo configure.js --with-php-build=..\build\php_build
--enable-debug --with-mysql=shared --with-xsl=shared
nmake


Previous Comments:


[2004-12-30 18:50:46] [EMAIL PROTECTED]

Are you sure that you have a clean build?



[2004-12-30 16:58:17] [EMAIL PROTECTED]

Description:

Serializing StdClass objects causes segfault in PHP_5_0 but not in
HEAD.

zend_std_get_method() (third stackframe) is called with __sleep as the
value for the method_name parameter so it looks like the serializer
tries to call a non-existant __sleep() method on the object.

Reproduce code:
---
?php
print serialize(new StdClass);
?


Expected result:

HEAD: O:8:stdClass:0:{}

Actual result:
--
PHP_5_0:

php5ts_debug.dll!zend_object_store_get_object(_zval_struct *
zobject=0x0001, void * * * tsrm_ls=0x00902c48)  Line 200 + 0x3  C
php5ts_debug.dll!zend_objects_get_address(_zval_struct *
zobject=0x0001, void * * * tsrm_ls=0x00902c48)  Line 111 + 0xd  C
php5ts_debug.dll!zend_std_get_method(_zval_struct * *
object_ptr=0x00a31d50, char * method_name=0x1058f1c8, int method_len=7,
void * * * tsrm_ls=0x00902c48)  Line 680 + 0xd  C
php5ts_debug.dll!zend_call_function(_zend_fcall_info * fci=0x0012ecc8,
_zend_fcall_info_cache * fci_cache=0x, void * * *
tsrm_ls=0x00902c48)  Line 688 + 0x30C
php5ts_debug.dll!call_user_function_ex(_hashtable *
function_table=0x00908d40, _zval_struct * * object_pp=0x00a214e4,
_zval_struct * function_name=0x0012ef60, _zval_struct * *
retval_ptr_ptr=0x0012ef78, unsigned int param_count=0, _zval_struct * *
* params=0x, int no_separation=1, _hashtable *
symbol_table=0x, void * * * tsrm_ls=0x00902c48)  Line 551 +
0xf C
php5ts_debug.dll!php_var_serialize_intern(smart_str * buf=0x0012f3b0,
_zval_struct * * struc=0x00a214e4, _hashtable * var_hash=0x0012f3c4,
void * * * tsrm_ls=0x00902c48)  Line 678 + 0x38 C
php5ts_debug.dll!php_var_serialize(smart_str * buf=0x0012f3b0,
_zval_struct * * struc=0x00a214e4, _hashtable * var_hash=0x0012f3c4,
void * * * tsrm_ls=0x00902c48)  Line 771 + 0x15 C
php5ts_debug.dll!zif_serialize(int ht=1, _zval_struct *
return_value=0x00a31de0, _zval_struct * this_ptr=0x, int
return_value_used=1, void * * * tsrm_ls=0x00902c48)  Line 794 + 0x15C
php5ts_debug.dll!zend_do_fcall_common_helper(_zend_execute_data *
execute_data=0x0012f744, _zend_op * opline=0x00a31a88, _zend_op_array *
op_array=0x00a31680, void * * * tsrm_ls=0x00902c48)  Line 2711 + 0x32   C
php5ts_debug.dll!zend_do_fcall_handler(_zend_execute_data *
execute_data=0x0012f744, _zend_op * opline=0x00a31a88, _zend_op_array *
op_array=0x00a31680, void * * * tsrm_ls=0x00902c48)  Line 2843 + 0x15   C
php5ts_debug.dll!execute(_zend_op_array * op_array=0x00a31680, void * *
* tsrm_ls=0x00902c48)  Line 1400 + 0x17 C
php5ts_debug.dll!zend_execute_scripts(int type=8, void * * *
tsrm_ls=0x00902c48, _zval_struct * * retval=0x, int
file_count=3, ...)  Line 1060 + 0x21C
php5ts_debug.dll!php_execute_script(_zend_file_handle *
primary_file=0x0012ff2c, void * * * tsrm_ls=0x00902c48)  Line 1628 +
0x1bC
php.exe!main(int argc=2, char * * argv=0x00904c68)  Line 943 + 0x13 C
php.exe!mainCRTStartup()  Line 398 + 0x11   C
kernel32.dll!7c816d4f()
kernel32.dll!7c8399f3()





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


#31359 [Opn]: Compile failure on file zend_strtod.c

2004-12-30 Thread cesare at wolfnet dot com
 ID:   31359
 User updated by:  cesare at wolfnet dot com
 Reported By:  cesare at wolfnet dot com
 Status:   Open
 Bug Type: Compile Failure
 Operating System: Solaris 9 x86
 PHP Version:  4.3.10
 New Comment:

I forgot to mention that it compiles fine on version 4.3.9 and 5.0.3.


Previous Comments:


[2004-12-30 22:22:20] cesare at wolfnet dot com

Description:

Compiling php with the follwing options:

./configure  --enable-track-vars --enable-force-cgi-redirect
--with-gettext --with-mysql=/opt/sfw/mysql
--with-apxs2=/usr/local/apache2/bin/apxs --with-libxml-dir=/opt/sfw/lib
--with-dom --with-iconv --enable-mbstring --with-mbstring=all
--with-zlib-dir=/opt/sfw/lib --with-gd --with-png-dir=/usr/local/lib
--with-jpeg-dir=/usr/local/lib --enable-ftp --with-ldap --with-imap

It fails with the following errors:

/bin/sh /src/lib/php/php-4.3.10/libtool --silent --preserve-dup-deps
--mode=compile gcc  -IZend/ -I/src/lib/php/php-4.3.10/Zend/
-DPHP_ATOM_INC -I/src/lib/php/php-4.3.10/include
-I/src/lib/php/php-4.3.10/main -I/src/lib/php/php-4.3.10
-I/src/lib/php/php-4.3.10/Zend -I/usr/include/libxml2
-I/usr/local/include -I/src/lib/php/php-4.3.10/ext/mbstring/mbregex
-I/src/lib/php/php-4.3.10/ext/mbstring/libmbfl
-I/src/lib/php/php-4.3.10/ext/mbstring/libmbfl/mbfl
-I/opt/sfw/mysql/include/mysql -I/src/lib/php/php-4.3.10/ext/xml/expat 
-D_POSIX_PTHREAD_SEMANTICS -I/src/lib/php/php-4.3.10/TSRM  -g -O2 
-prefer-pic -c /src/lib/php/php-4.3.10/Zend/zend_strtod.c -o
Zend/zend_strtod.lo 
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:239: parse error before
`u_int32_t'
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:239: warning: no semicolon
at end of struct or union
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:240: warning: data
definition has no type or storage class
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:386: parse error before
`u_int32_t'
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:386: warning: no semicolon
at end of struct or union
/src/lib/php/php-4.3.10/Zend/zend_strtod.c: In function `Balloc':
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:405: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:409: sizeof applied to an
incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:410: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:411: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:413: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:413: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c: In function `Bfree':
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:426: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:426: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:427: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c: In function `multadd':
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:443: `u_int32_t' undeclared
(first use in this function)
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:443: (Each undeclared
identifier is reported only once
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:443: for each function it
appears in.)
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:443: `x' undeclared (first
use in this function)
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:443: `y' undeclared (first
use in this function)
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:445: parse error before
`xi'
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:449: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:450: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:454: `xi' undeclared (first
use in this function)
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:456: `z' undeclared (first
use in this function)
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:467: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:468: `b1' undeclared (first
use in this function)
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:468: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:469: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:469: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:473: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:474: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c: At top level:
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:484: parse error before
`u_int32_t'
/src/lib/php/php-4.3.10/Zend/zend_strtod.c: In function `s2b':
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:491: `nd' undeclared (first
use in this function)
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:495: dereferencing pointer
to incomplete type

#31356 [Csd]: Serializing StdClass objects causes segfault

2004-12-30 Thread [EMAIL PROTECTED]
 ID:   31356
 User updated by:  [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
 Status:   Closed
 Bug Type: Reproducible crash
 Operating System: Windows XP SP-2
 PHP Version:  5CVS-2004-12-30 (dev)
 New Comment:

-not +now :-)


Previous Comments:


[2004-12-30 22:29:54] [EMAIL PROTECTED]

I made a clean checkout and rebuilt -- and not it works.

Below is the build script I use which I think should clean everything
before building:

cscript /nologo win32\build\cvsclean.js
rmdir /S /Q debug_ts
cscript /nologo win32\build\buildconf.js
cscript /nologo configure.js --with-php-build=..\build\php_build
--enable-debug --with-mysql=shared --with-xsl=shared
nmake



[2004-12-30 18:50:46] [EMAIL PROTECTED]

Are you sure that you have a clean build?



[2004-12-30 16:58:17] [EMAIL PROTECTED]

Description:

Serializing StdClass objects causes segfault in PHP_5_0 but not in
HEAD.

zend_std_get_method() (third stackframe) is called with __sleep as the
value for the method_name parameter so it looks like the serializer
tries to call a non-existant __sleep() method on the object.

Reproduce code:
---
?php
print serialize(new StdClass);
?


Expected result:

HEAD: O:8:stdClass:0:{}

Actual result:
--
PHP_5_0:

php5ts_debug.dll!zend_object_store_get_object(_zval_struct *
zobject=0x0001, void * * * tsrm_ls=0x00902c48)  Line 200 + 0x3  C
php5ts_debug.dll!zend_objects_get_address(_zval_struct *
zobject=0x0001, void * * * tsrm_ls=0x00902c48)  Line 111 + 0xd  C
php5ts_debug.dll!zend_std_get_method(_zval_struct * *
object_ptr=0x00a31d50, char * method_name=0x1058f1c8, int method_len=7,
void * * * tsrm_ls=0x00902c48)  Line 680 + 0xd  C
php5ts_debug.dll!zend_call_function(_zend_fcall_info * fci=0x0012ecc8,
_zend_fcall_info_cache * fci_cache=0x, void * * *
tsrm_ls=0x00902c48)  Line 688 + 0x30C
php5ts_debug.dll!call_user_function_ex(_hashtable *
function_table=0x00908d40, _zval_struct * * object_pp=0x00a214e4,
_zval_struct * function_name=0x0012ef60, _zval_struct * *
retval_ptr_ptr=0x0012ef78, unsigned int param_count=0, _zval_struct * *
* params=0x, int no_separation=1, _hashtable *
symbol_table=0x, void * * * tsrm_ls=0x00902c48)  Line 551 +
0xf C
php5ts_debug.dll!php_var_serialize_intern(smart_str * buf=0x0012f3b0,
_zval_struct * * struc=0x00a214e4, _hashtable * var_hash=0x0012f3c4,
void * * * tsrm_ls=0x00902c48)  Line 678 + 0x38 C
php5ts_debug.dll!php_var_serialize(smart_str * buf=0x0012f3b0,
_zval_struct * * struc=0x00a214e4, _hashtable * var_hash=0x0012f3c4,
void * * * tsrm_ls=0x00902c48)  Line 771 + 0x15 C
php5ts_debug.dll!zif_serialize(int ht=1, _zval_struct *
return_value=0x00a31de0, _zval_struct * this_ptr=0x, int
return_value_used=1, void * * * tsrm_ls=0x00902c48)  Line 794 + 0x15C
php5ts_debug.dll!zend_do_fcall_common_helper(_zend_execute_data *
execute_data=0x0012f744, _zend_op * opline=0x00a31a88, _zend_op_array *
op_array=0x00a31680, void * * * tsrm_ls=0x00902c48)  Line 2711 + 0x32   C
php5ts_debug.dll!zend_do_fcall_handler(_zend_execute_data *
execute_data=0x0012f744, _zend_op * opline=0x00a31a88, _zend_op_array *
op_array=0x00a31680, void * * * tsrm_ls=0x00902c48)  Line 2843 + 0x15   C
php5ts_debug.dll!execute(_zend_op_array * op_array=0x00a31680, void * *
* tsrm_ls=0x00902c48)  Line 1400 + 0x17 C
php5ts_debug.dll!zend_execute_scripts(int type=8, void * * *
tsrm_ls=0x00902c48, _zval_struct * * retval=0x, int
file_count=3, ...)  Line 1060 + 0x21C
php5ts_debug.dll!php_execute_script(_zend_file_handle *
primary_file=0x0012ff2c, void * * * tsrm_ls=0x00902c48)  Line 1628 +
0x1bC
php.exe!main(int argc=2, char * * argv=0x00904c68)  Line 943 + 0x13 C
php.exe!mainCRTStartup()  Line 398 + 0x11   C
kernel32.dll!7c816d4f()
kernel32.dll!7c8399f3()





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


#31358 [NEW]: Compile time error, incompatible types in assignment

2004-12-30 Thread hawk at pld-linux dot org
From: hawk at pld-linux dot org
Operating system: PLD Linux running on PowerPC
PHP version:  4.3.10
PHP Bug Type: Compile Failure
Bug description:  Compile time error, incompatible types in assignment

Description:

The compilation of PHP 4.3.10 fails on Linux running on PowerPC with
following error:

/home/users/builder/rpm/BUILD/php-4.3.10/Zend/zend.c -o Zend/zend.lo 
/home/users/builder/rpm/BUILD/php-4.3.10/Zend/zend.c: In function
`zend_error':
/home/users/builder/rpm/BUILD/php-4.3.10/Zend/zend.c:776: incompatible
types in assignment
make: *** [Zend/zend.lo] Error 1

Following code change is reponsible for this bug:
cvs diff -u -r 1.162.2.21 -r 1.162.2.22 Zend/zend.c

Line 776 is:
usr_copy = args;
where both usr_copy and args are of type va_list. Such code will not
compile on Linux on PowerPC (and probably on some other architectures too)
because va_list is struct here.

I know only two ways for fixing it. One is to use va_copy, but I'm not
sure if its safe to change following portion of code:

#if defined(va_copy)
   va_copy(usr_copy, args);
#else
   usr_copy = args;
#endif

just into:

va_copy(usr_copy, args);

Probably its not safe. The second way is to use
usr_copy[0] = args[0];
for the affected architectures, but its not safe either AFAIR.

I also suppose that php 5.0.3 is affected too, because it contains same
code


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


#31359 [NEW]: Compile failure on file zend_strtod.c

2004-12-30 Thread cesare at wolfnet dot com
From: cesare at wolfnet dot com
Operating system: Solaris 9 x86
PHP version:  4.3.10
PHP Bug Type: Compile Failure
Bug description:  Compile failure on file zend_strtod.c

Description:

Compiling php with the follwing options:

./configure  --enable-track-vars --enable-force-cgi-redirect
--with-gettext --with-mysql=/opt/sfw/mysql
--with-apxs2=/usr/local/apache2/bin/apxs --with-libxml-dir=/opt/sfw/lib
--with-dom --with-iconv --enable-mbstring --with-mbstring=all
--with-zlib-dir=/opt/sfw/lib --with-gd --with-png-dir=/usr/local/lib
--with-jpeg-dir=/usr/local/lib --enable-ftp --with-ldap --with-imap

It fails with the following errors:

/bin/sh /src/lib/php/php-4.3.10/libtool --silent --preserve-dup-deps
--mode=compile gcc  -IZend/ -I/src/lib/php/php-4.3.10/Zend/ -DPHP_ATOM_INC
-I/src/lib/php/php-4.3.10/include -I/src/lib/php/php-4.3.10/main
-I/src/lib/php/php-4.3.10 -I/src/lib/php/php-4.3.10/Zend
-I/usr/include/libxml2 -I/usr/local/include
-I/src/lib/php/php-4.3.10/ext/mbstring/mbregex
-I/src/lib/php/php-4.3.10/ext/mbstring/libmbfl
-I/src/lib/php/php-4.3.10/ext/mbstring/libmbfl/mbfl
-I/opt/sfw/mysql/include/mysql -I/src/lib/php/php-4.3.10/ext/xml/expat 
-D_POSIX_PTHREAD_SEMANTICS -I/src/lib/php/php-4.3.10/TSRM  -g -O2 
-prefer-pic -c /src/lib/php/php-4.3.10/Zend/zend_strtod.c -o
Zend/zend_strtod.lo 
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:239: parse error before
`u_int32_t'
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:239: warning: no semicolon at
end of struct or union
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:240: warning: data definition
has no type or storage class
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:386: parse error before
`u_int32_t'
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:386: warning: no semicolon at
end of struct or union
/src/lib/php/php-4.3.10/Zend/zend_strtod.c: In function `Balloc':
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:405: dereferencing pointer to
incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:409: sizeof applied to an
incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:410: dereferencing pointer to
incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:411: dereferencing pointer to
incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:413: dereferencing pointer to
incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:413: dereferencing pointer to
incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c: In function `Bfree':
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:426: dereferencing pointer to
incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:426: dereferencing pointer to
incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:427: dereferencing pointer to
incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c: In function `multadd':
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:443: `u_int32_t' undeclared
(first use in this function)
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:443: (Each undeclared
identifier is reported only once
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:443: for each function it
appears in.)
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:443: `x' undeclared (first use
in this function)
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:443: `y' undeclared (first use
in this function)
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:445: parse error before `xi'
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:449: dereferencing pointer to
incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:450: dereferencing pointer to
incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:454: `xi' undeclared (first use
in this function)
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:456: `z' undeclared (first use
in this function)
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:467: dereferencing pointer to
incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:468: `b1' undeclared (first use
in this function)
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:468: dereferencing pointer to
incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:469: dereferencing pointer to
incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:469: dereferencing pointer to
incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:473: dereferencing pointer to
incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:474: dereferencing pointer to
incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c: At top level:
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:484: parse error before
`u_int32_t'
/src/lib/php/php-4.3.10/Zend/zend_strtod.c: In function `s2b':
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:491: `nd' undeclared (first use
in this function)
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:495: dereferencing pointer to
incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:495: `y9' undeclared (first use
in this function)
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:496: dereferencing pointer to
incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:504: `nd0' undeclared (first
use in this function)

#31357 [NEW]: PHP gives indulgences when a developer uses wrong escaping

2004-12-30 Thread wicked at ngs dot ru
From: wicked at ngs dot ru
Operating system: Win XP + SP1
PHP version:  4.3.8
PHP Bug Type: Scripting Engine problem
Bug description:  PHP gives indulgences when a developer uses wrong escaping

Description:

I expect that
print \a;
will fail because there is no entity like \a among
\n, \r, \t, \\, \$, \, \[0-7]{1,3} and \x[0-9A-Fa-f]{1,2}.

It is like that browsers like IE shows abc as there were written
amp;abc.

It's harmful.

More than that, I and some other PHP experts have been puzzleing why this
string works:

$tokens   = preg_split('/(?!\\\)[?!]/', $query, -1,
   PREG_SPLIT_DELIM_CAPTURE);

Everybody expected that ) was escaped!

Reproduce code:
---
$tokens   = preg_split('/(?!\\\)[?!]/', $query, -1,
   PREG_SPLIT_DELIM_CAPTURE);

Expected result:

PHP fails because of brackets mismatch (one of brackets is escaped).

Actual result:
--
It works :(

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


#31359 [Opn]: Compile failure on file zend_strtod.c

2004-12-30 Thread cesare at wolfnet dot com
 ID:   31359
 User updated by:  cesare at wolfnet dot com
 Reported By:  cesare at wolfnet dot com
 Status:   Open
 Bug Type: Compile Failure
 Operating System: Solaris 9 x86
 PHP Version:  4.3.10
 New Comment:

Sorry 5.0.3 does not compile either, it was with RC1


Previous Comments:


[2004-12-30 22:30:44] cesare at wolfnet dot com

I forgot to mention that it compiles fine on version 4.3.9 and 5.0.3.



[2004-12-30 22:22:20] cesare at wolfnet dot com

Description:

Compiling php with the follwing options:

./configure  --enable-track-vars --enable-force-cgi-redirect
--with-gettext --with-mysql=/opt/sfw/mysql
--with-apxs2=/usr/local/apache2/bin/apxs --with-libxml-dir=/opt/sfw/lib
--with-dom --with-iconv --enable-mbstring --with-mbstring=all
--with-zlib-dir=/opt/sfw/lib --with-gd --with-png-dir=/usr/local/lib
--with-jpeg-dir=/usr/local/lib --enable-ftp --with-ldap --with-imap

It fails with the following errors:

/bin/sh /src/lib/php/php-4.3.10/libtool --silent --preserve-dup-deps
--mode=compile gcc  -IZend/ -I/src/lib/php/php-4.3.10/Zend/
-DPHP_ATOM_INC -I/src/lib/php/php-4.3.10/include
-I/src/lib/php/php-4.3.10/main -I/src/lib/php/php-4.3.10
-I/src/lib/php/php-4.3.10/Zend -I/usr/include/libxml2
-I/usr/local/include -I/src/lib/php/php-4.3.10/ext/mbstring/mbregex
-I/src/lib/php/php-4.3.10/ext/mbstring/libmbfl
-I/src/lib/php/php-4.3.10/ext/mbstring/libmbfl/mbfl
-I/opt/sfw/mysql/include/mysql -I/src/lib/php/php-4.3.10/ext/xml/expat 
-D_POSIX_PTHREAD_SEMANTICS -I/src/lib/php/php-4.3.10/TSRM  -g -O2 
-prefer-pic -c /src/lib/php/php-4.3.10/Zend/zend_strtod.c -o
Zend/zend_strtod.lo 
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:239: parse error before
`u_int32_t'
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:239: warning: no semicolon
at end of struct or union
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:240: warning: data
definition has no type or storage class
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:386: parse error before
`u_int32_t'
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:386: warning: no semicolon
at end of struct or union
/src/lib/php/php-4.3.10/Zend/zend_strtod.c: In function `Balloc':
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:405: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:409: sizeof applied to an
incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:410: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:411: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:413: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:413: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c: In function `Bfree':
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:426: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:426: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:427: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c: In function `multadd':
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:443: `u_int32_t' undeclared
(first use in this function)
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:443: (Each undeclared
identifier is reported only once
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:443: for each function it
appears in.)
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:443: `x' undeclared (first
use in this function)
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:443: `y' undeclared (first
use in this function)
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:445: parse error before
`xi'
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:449: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:450: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:454: `xi' undeclared (first
use in this function)
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:456: `z' undeclared (first
use in this function)
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:467: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:468: `b1' undeclared (first
use in this function)
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:468: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:469: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:469: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:473: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:474: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c: At top level:
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:484: parse error before
`u_int32_t'
/src/lib/php/php-4.3.10/Zend/zend_strtod.c: In function `s2b':

#31356 [Csd-Bgs]: Serializing StdClass objects causes segfault

2004-12-30 Thread johannes
 ID:   31356
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Closed
+Status:   Bogus
 Bug Type: Reproducible crash
 Operating System: Windows XP SP-2
 PHP Version:  5CVS-2004-12-30 (dev)
 New Comment:

no bug - bogus 


Previous Comments:


[2004-12-30 22:30:29] [EMAIL PROTECTED]

-not +now :-)



[2004-12-30 22:29:54] [EMAIL PROTECTED]

I made a clean checkout and rebuilt -- and not it works.

Below is the build script I use which I think should clean everything
before building:

cscript /nologo win32\build\cvsclean.js
rmdir /S /Q debug_ts
cscript /nologo win32\build\buildconf.js
cscript /nologo configure.js --with-php-build=..\build\php_build
--enable-debug --with-mysql=shared --with-xsl=shared
nmake



[2004-12-30 18:50:46] [EMAIL PROTECTED]

Are you sure that you have a clean build?



[2004-12-30 16:58:17] [EMAIL PROTECTED]

Description:

Serializing StdClass objects causes segfault in PHP_5_0 but not in
HEAD.

zend_std_get_method() (third stackframe) is called with __sleep as the
value for the method_name parameter so it looks like the serializer
tries to call a non-existant __sleep() method on the object.

Reproduce code:
---
?php
print serialize(new StdClass);
?


Expected result:

HEAD: O:8:stdClass:0:{}

Actual result:
--
PHP_5_0:

php5ts_debug.dll!zend_object_store_get_object(_zval_struct *
zobject=0x0001, void * * * tsrm_ls=0x00902c48)  Line 200 + 0x3  C
php5ts_debug.dll!zend_objects_get_address(_zval_struct *
zobject=0x0001, void * * * tsrm_ls=0x00902c48)  Line 111 + 0xd  C
php5ts_debug.dll!zend_std_get_method(_zval_struct * *
object_ptr=0x00a31d50, char * method_name=0x1058f1c8, int method_len=7,
void * * * tsrm_ls=0x00902c48)  Line 680 + 0xd  C
php5ts_debug.dll!zend_call_function(_zend_fcall_info * fci=0x0012ecc8,
_zend_fcall_info_cache * fci_cache=0x, void * * *
tsrm_ls=0x00902c48)  Line 688 + 0x30C
php5ts_debug.dll!call_user_function_ex(_hashtable *
function_table=0x00908d40, _zval_struct * * object_pp=0x00a214e4,
_zval_struct * function_name=0x0012ef60, _zval_struct * *
retval_ptr_ptr=0x0012ef78, unsigned int param_count=0, _zval_struct * *
* params=0x, int no_separation=1, _hashtable *
symbol_table=0x, void * * * tsrm_ls=0x00902c48)  Line 551 +
0xf C
php5ts_debug.dll!php_var_serialize_intern(smart_str * buf=0x0012f3b0,
_zval_struct * * struc=0x00a214e4, _hashtable * var_hash=0x0012f3c4,
void * * * tsrm_ls=0x00902c48)  Line 678 + 0x38 C
php5ts_debug.dll!php_var_serialize(smart_str * buf=0x0012f3b0,
_zval_struct * * struc=0x00a214e4, _hashtable * var_hash=0x0012f3c4,
void * * * tsrm_ls=0x00902c48)  Line 771 + 0x15 C
php5ts_debug.dll!zif_serialize(int ht=1, _zval_struct *
return_value=0x00a31de0, _zval_struct * this_ptr=0x, int
return_value_used=1, void * * * tsrm_ls=0x00902c48)  Line 794 + 0x15C
php5ts_debug.dll!zend_do_fcall_common_helper(_zend_execute_data *
execute_data=0x0012f744, _zend_op * opline=0x00a31a88, _zend_op_array *
op_array=0x00a31680, void * * * tsrm_ls=0x00902c48)  Line 2711 + 0x32   C
php5ts_debug.dll!zend_do_fcall_handler(_zend_execute_data *
execute_data=0x0012f744, _zend_op * opline=0x00a31a88, _zend_op_array *
op_array=0x00a31680, void * * * tsrm_ls=0x00902c48)  Line 2843 + 0x15   C
php5ts_debug.dll!execute(_zend_op_array * op_array=0x00a31680, void * *
* tsrm_ls=0x00902c48)  Line 1400 + 0x17 C
php5ts_debug.dll!zend_execute_scripts(int type=8, void * * *
tsrm_ls=0x00902c48, _zval_struct * * retval=0x, int
file_count=3, ...)  Line 1060 + 0x21C
php5ts_debug.dll!php_execute_script(_zend_file_handle *
primary_file=0x0012ff2c, void * * * tsrm_ls=0x00902c48)  Line 1628 +
0x1bC
php.exe!main(int argc=2, char * * argv=0x00904c68)  Line 943 + 0x13 C
php.exe!mainCRTStartup()  Line 398 + 0x11   C
kernel32.dll!7c816d4f()
kernel32.dll!7c8399f3()





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


#31359 [Opn-Fbk]: Compile failure on file zend_strtod.c

2004-12-30 Thread tony2001
 ID:   31359
 Updated by:   [EMAIL PROTECTED]
 Reported By:  cesare at wolfnet dot com
-Status:   Open
+Status:   Feedback
 Bug Type: Compile Failure
 Operating System: Solaris 9 x86
 PHP Version:  4.3.10
 New Comment:

Please try using this CVS snapshot:

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




Previous Comments:


[2004-12-30 22:56:52] cesare at wolfnet dot com

Sorry 5.0.3 does not compile either, it was with RC1



[2004-12-30 22:30:44] cesare at wolfnet dot com

I forgot to mention that it compiles fine on version 4.3.9 and 5.0.3.



[2004-12-30 22:22:20] cesare at wolfnet dot com

Description:

Compiling php with the follwing options:

./configure  --enable-track-vars --enable-force-cgi-redirect
--with-gettext --with-mysql=/opt/sfw/mysql
--with-apxs2=/usr/local/apache2/bin/apxs --with-libxml-dir=/opt/sfw/lib
--with-dom --with-iconv --enable-mbstring --with-mbstring=all
--with-zlib-dir=/opt/sfw/lib --with-gd --with-png-dir=/usr/local/lib
--with-jpeg-dir=/usr/local/lib --enable-ftp --with-ldap --with-imap

It fails with the following errors:

/bin/sh /src/lib/php/php-4.3.10/libtool --silent --preserve-dup-deps
--mode=compile gcc  -IZend/ -I/src/lib/php/php-4.3.10/Zend/
-DPHP_ATOM_INC -I/src/lib/php/php-4.3.10/include
-I/src/lib/php/php-4.3.10/main -I/src/lib/php/php-4.3.10
-I/src/lib/php/php-4.3.10/Zend -I/usr/include/libxml2
-I/usr/local/include -I/src/lib/php/php-4.3.10/ext/mbstring/mbregex
-I/src/lib/php/php-4.3.10/ext/mbstring/libmbfl
-I/src/lib/php/php-4.3.10/ext/mbstring/libmbfl/mbfl
-I/opt/sfw/mysql/include/mysql -I/src/lib/php/php-4.3.10/ext/xml/expat 
-D_POSIX_PTHREAD_SEMANTICS -I/src/lib/php/php-4.3.10/TSRM  -g -O2 
-prefer-pic -c /src/lib/php/php-4.3.10/Zend/zend_strtod.c -o
Zend/zend_strtod.lo 
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:239: parse error before
`u_int32_t'
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:239: warning: no semicolon
at end of struct or union
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:240: warning: data
definition has no type or storage class
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:386: parse error before
`u_int32_t'
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:386: warning: no semicolon
at end of struct or union
/src/lib/php/php-4.3.10/Zend/zend_strtod.c: In function `Balloc':
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:405: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:409: sizeof applied to an
incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:410: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:411: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:413: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:413: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c: In function `Bfree':
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:426: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:426: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:427: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c: In function `multadd':
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:443: `u_int32_t' undeclared
(first use in this function)
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:443: (Each undeclared
identifier is reported only once
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:443: for each function it
appears in.)
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:443: `x' undeclared (first
use in this function)
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:443: `y' undeclared (first
use in this function)
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:445: parse error before
`xi'
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:449: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:450: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:454: `xi' undeclared (first
use in this function)
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:456: `z' undeclared (first
use in this function)
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:467: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:468: `b1' undeclared (first
use in this function)
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:468: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:469: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:469: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:473: dereferencing pointer
to incomplete type

#31357 [Opn-Bgs]: PHP gives indulgences when a developer uses wrong escaping

2004-12-30 Thread tony2001
 ID:   31357
 Updated by:   [EMAIL PROTECTED]
 Reported By:  wicked at ngs dot ru
-Status:   Open
+Status:   Bogus
 Bug Type: Scripting Engine problem
 Operating System: Win XP + SP1
 PHP Version:  4.3.8
 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

Escaped characters are pretty well documented and I don't understand
what do you complain about.
See here: http://www.php.net/manual/en/language.types.string.php


Previous Comments:


[2004-12-30 20:41:16] wicked at ngs dot ru

Description:

I expect that
print \a;
will fail because there is no entity like \a among
\n, \r, \t, \\, \$, \, \[0-7]{1,3} and \x[0-9A-Fa-f]{1,2}.

It is like that browsers like IE shows abc as there were written
amp;abc.

It's harmful.

More than that, I and some other PHP experts have been puzzleing why
this string works:

$tokens   = preg_split('/(?!\\\)[?!]/', $query, -1,
   PREG_SPLIT_DELIM_CAPTURE);

Everybody expected that ) was escaped!

Reproduce code:
---
$tokens   = preg_split('/(?!\\\)[?!]/', $query, -1,
   PREG_SPLIT_DELIM_CAPTURE);

Expected result:

PHP fails because of brackets mismatch (one of brackets is escaped).

Actual result:
--
It works :(





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


#31359 [Fbk-Csd]: Compile failure on file zend_strtod.c

2004-12-30 Thread derick
 ID:   31359
 Updated by:   [EMAIL PROTECTED]
 Reported By:  cesare at wolfnet dot com
-Status:   Feedback
+Status:   Closed
 Bug Type: Compile Failure
 Operating System: Solaris 9 x86
 PHP Version:  4.3.10
 New Comment:

This bug has been fixed in CVS.

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


Previous Comments:


[2004-12-31 00:46:54] [EMAIL PROTECTED]

Please try using this CVS snapshot:

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





[2004-12-30 22:56:52] cesare at wolfnet dot com

Sorry 5.0.3 does not compile either, it was with RC1



[2004-12-30 22:30:44] cesare at wolfnet dot com

I forgot to mention that it compiles fine on version 4.3.9 and 5.0.3.



[2004-12-30 22:22:20] cesare at wolfnet dot com

Description:

Compiling php with the follwing options:

./configure  --enable-track-vars --enable-force-cgi-redirect
--with-gettext --with-mysql=/opt/sfw/mysql
--with-apxs2=/usr/local/apache2/bin/apxs --with-libxml-dir=/opt/sfw/lib
--with-dom --with-iconv --enable-mbstring --with-mbstring=all
--with-zlib-dir=/opt/sfw/lib --with-gd --with-png-dir=/usr/local/lib
--with-jpeg-dir=/usr/local/lib --enable-ftp --with-ldap --with-imap

It fails with the following errors:

/bin/sh /src/lib/php/php-4.3.10/libtool --silent --preserve-dup-deps
--mode=compile gcc  -IZend/ -I/src/lib/php/php-4.3.10/Zend/
-DPHP_ATOM_INC -I/src/lib/php/php-4.3.10/include
-I/src/lib/php/php-4.3.10/main -I/src/lib/php/php-4.3.10
-I/src/lib/php/php-4.3.10/Zend -I/usr/include/libxml2
-I/usr/local/include -I/src/lib/php/php-4.3.10/ext/mbstring/mbregex
-I/src/lib/php/php-4.3.10/ext/mbstring/libmbfl
-I/src/lib/php/php-4.3.10/ext/mbstring/libmbfl/mbfl
-I/opt/sfw/mysql/include/mysql -I/src/lib/php/php-4.3.10/ext/xml/expat 
-D_POSIX_PTHREAD_SEMANTICS -I/src/lib/php/php-4.3.10/TSRM  -g -O2 
-prefer-pic -c /src/lib/php/php-4.3.10/Zend/zend_strtod.c -o
Zend/zend_strtod.lo 
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:239: parse error before
`u_int32_t'
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:239: warning: no semicolon
at end of struct or union
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:240: warning: data
definition has no type or storage class
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:386: parse error before
`u_int32_t'
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:386: warning: no semicolon
at end of struct or union
/src/lib/php/php-4.3.10/Zend/zend_strtod.c: In function `Balloc':
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:405: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:409: sizeof applied to an
incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:410: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:411: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:413: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:413: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c: In function `Bfree':
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:426: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:426: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:427: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c: In function `multadd':
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:443: `u_int32_t' undeclared
(first use in this function)
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:443: (Each undeclared
identifier is reported only once
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:443: for each function it
appears in.)
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:443: `x' undeclared (first
use in this function)
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:443: `y' undeclared (first
use in this function)
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:445: parse error before
`xi'
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:449: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:450: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:454: `xi' undeclared (first
use in this function)
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:456: `z' undeclared (first
use in this function)
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:467: dereferencing pointer
to incomplete type
/src/lib/php/php-4.3.10/Zend/zend_strtod.c:468: `b1' undeclared (first
use in this function)

#31350 [Opn-Bgs]: Max reading length of STDIN is 8192bytes

2004-12-30 Thread derick
 ID:   31350
 Updated by:   [EMAIL PROTECTED]
 Reported By:  gibspam at carnation dot hu
-Status:   Open
+Status:   Bogus
 Bug Type: Filesystem function related
 Operating System: Redhat Linux 7.1-7.3
 PHP Version:  4.3.10
 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

.


Previous Comments:


[2004-12-30 11:59:12] gibspam at carnation dot hu

Description:

I write a script which reads a file from STDIN, and writes it out the
content of it to a new file. It worked fine with php 4.3.4, but when I
upgraded to any newer version, then it failed to read the whole file
from stdin. I expected to read the file into a 128000 bytes buffer but
it reads only 8192 bytes instead of 128000 bytes.

Reproduce code:
---
?
$file_length = 6596594;
define(UPLOAD_BUFFER,128000);

if (!$fp = fopen(test.data,w))
{
die(file open error);
}

$count =  (($file_length / UPLOAD_BUFFER));
echo \nmax i should be: .$count;
for ($i = 1; $i  $count; $i ++) {
$str = fread(STDIN, UPLOAD_BUFFER);
echo \ni: .$i. length:.strlen($str);
fwrite($fp, $str);
}

$remainder = $file_length % UPLOAD_BUFFER;

if (0 != $remainder) {
$str = fread(STDIN, $remainder);
echo \nlast length:.strlen($str);
fwrite($fp, fread(STDIN, $remainder));
}

fclose($fp);
?


Expected result:

If I run my script with this command:
php -q ./my.php  file_with_size_of_6596594_bytes.bin

I expect to get a new file created (test.data), with the same content
as the file_with_size_of_6596594_bytes.bin.

Actual result:
--
As a result a new file created (test.data), which is 425984 bytes
long.

425984=51*8192+8192

But, it shuld be

6596594=51*128000+68594







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


#31344 [Opn-Fbk]: PHP 4.3.10 crashed Apache without message

2004-12-30 Thread iliaa
 ID:   31344
 Updated by:   [EMAIL PROTECTED]
 Reported By:  sysadmin at amhosting dot com
-Status:   Open
+Status:   Feedback
 Bug Type: Apache2 related
 Operating System: Red Hat 9 + Legacy
 PHP Version:  4.3.10
 New Comment:

Thank you for this bug report. To properly diagnose the problem, we
need a backtrace to see what is happening behind the scenes. To
find out how to generate a backtrace, please read
http://bugs.php.net/bugs-generating-backtrace.php

Once you have generated a backtrace, please submit it to this bug
report and change the status back to Open. Thank you for helping
us make PHP better.




Previous Comments:


[2004-12-30 18:29:27] sysadmin at amhosting dot com

The example script, run in the bash shell, looks something like this
for Red Hat 9:

---start of script---
#!/bin/bash
service httpd start
sleep 3
ps ax | grep httpd
---end of script---

What I expect is to see a number of processes with the name httpd
with PID numbers, all different.

Before PHP install, I get that.

After PHP install, I get grep httpd

Remove PHP from the system, it works again.

Script enough for you?



[2004-12-30 13:39:01] [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 ?php and ends 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 avoid embedding huge scripts into the report.





[2004-12-30 13:22:50] egor at ensita dot net

the latest stable doesn't help. :(



[2004-12-30 08:10:14] [EMAIL PROTECTED]

Please try using this CVS snapshot:

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





[2004-12-30 07:51:26] sysadmin at amhosting dot com

Description:

In trying to upgrade my Plesk servers, I have found that one upgrade
worked, the rest bombed out.  To reduce the number of variables, I
built a Red Hat 9 server from CDs, installed Yum, ran a full upgrade
cycle, then tried to install 4.3.10.  Apache would not start, or would
crash immediately without any tombstones.

Reproduce code:
---
Load Red Hat 9 from CDs.
Install Yum per instructions from Fedora Legacy project
yum update
download php source.
./configure parameters
make
make install

Expected result:

I expected PHP 4.3.10 to install and run normally.

Actual result:
--
Apache died without a trace.  service httpd status said that the
service was dead but a PID file was in place.





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


#31360 [NEW]: Maybe Array operation has some bug

2004-12-30 Thread tokimeki at 1111 dot com dot tw
From: tokimeki at  dot com dot tw
Operating system: FreeBSD / Windows XP
PHP version:  5.0.3
PHP Bug Type: Arrays related
Bug description:  Maybe Array operation has some bug

Description:

look the two source, index.php and debug.php.
At index.php (line 29), after array copy, and call show_var to show $arr
or $test, I get a error.


Reproduce code:
---
http://timteam.org/?TIM=FORUMFORUM=1ShowDocument=12961#TIM12961

Expected result:

ok
(array) = {
obj (object) = {}
str (string) = str
arr (array) = {}
number (integer) = 100
bool (boolean) = 1
null (NULL) = 
test (array) = {
AAA (string) = 000
BBB (array) = {
zzz (string) = Z
xxx (array) = {
zzz (string) = Z
xxx (array) - (@[test][BBB][xxx])
}
yyy (array) = {
www (array) - (@[test][BBB])
vvv (array) - (@[test][BBB])
}
}
CCC (array) - (@)
DDD (string) = ABC
EEE (array) - (@[test][BBB][yyy])
FFF (array) - (@[test][BBB])
[EMAIL PROTECTED]*()_+|~`\:;,.? (array) = {
TEST (string) = [EMAIL PROTECTED]*()_+|~`\:;,.?
}
  (array) - (@[test][[EMAIL PROTECTED]*()_+|~`\:;,.?])
}
}



Actual result:
--
ok
Fatal error: Allowed memory size of 8388608 bytes exhausted (tried to
allocate 128 bytes) in /home/tokimeki/public_html/test/debug.php on line
29

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


#31360 [Opn-Bgs]: Maybe Array operation has some bug

2004-12-30 Thread iliaa
 ID:   31360
 Updated by:   [EMAIL PROTECTED]
 Reported By:  tokimeki at  dot com dot tw
-Status:   Open
+Status:   Bogus
 Bug Type: Arrays related
 Operating System: FreeBSD / Windows XP
 PHP Version:  5.0.3
 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

Increase the memory limit, in your code you end up duplicating lot's of
data which causes this limit to be reached.


Previous Comments:


[2004-12-31 02:40:09] tokimeki at  dot com dot tw

Description:

look the two source, index.php and debug.php.
At index.php (line 29), after array copy, and call show_var to show
$arr or $test, I get a error.


Reproduce code:
---
http://timteam.org/?TIM=FORUMFORUM=1ShowDocument=12961#TIM12961

Expected result:

ok
(array) = {
obj (object) = {}
str (string) = str
arr (array) = {}
number (integer) = 100
bool (boolean) = 1
null (NULL) = 
test (array) = {
AAA (string) = 000
BBB (array) = {
zzz (string) = Z
xxx (array) = {
zzz (string) = Z
xxx (array) - (@[test][BBB][xxx])
}
yyy (array) = {
www (array) - (@[test][BBB])
vvv (array) - (@[test][BBB])
}
}
CCC (array) - (@)
DDD (string) = ABC
EEE (array) - (@[test][BBB][yyy])
FFF (array) - (@[test][BBB])
[EMAIL PROTECTED]*()_+|~`\:;,.? (array) = {
TEST (string) = [EMAIL PROTECTED]*()_+|~`\:;,.?
}
  (array) - (@[test][[EMAIL PROTECTED]*()_+|~`\:;,.?])
}
}



Actual result:
--
ok
Fatal error: Allowed memory size of 8388608 bytes exhausted (tried to
allocate 128 bytes) in /home/tokimeki/public_html/test/debug.php on
line 29





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


#31349 [Opn-Fbk]: Segmentation fault in mysql_query()

2004-12-30 Thread iliaa
 ID:   31349
 Updated by:   [EMAIL PROTECTED]
 Reported By:  bugs dot php dot net at chsc dot dk
-Status:   Open
+Status:   Feedback
 Bug Type: MySQL related
 Operating System: Linux
 PHP Version:  5.0.3
 New Comment:

Please compile your PHP with debugging symbols and re-run the crash
script.


Previous Comments:


[2004-12-30 14:44:13] bugs dot php dot net at chsc dot dk

I appears that if I change the queries slightly, e.g. add a /* comment
*/ to the end of the SQL string, or remove additional whitespace
outsite strings, everything works as expected.

It may be related to this bug: http://bugs.mysql.com/bug.php?id=5607



[2004-12-30 11:56:20] bugs dot php dot net at chsc dot dk

Description:

I have a rather complex script that dumps core every time mysql_query()
is called for the 7th time (through PEAR's DB_mysql).

The script uses Smarty, PEAR_DB and a bunch of other classes. I have
not been able to make a simple testcase. Doing the seven SQL queries
alone without Smarty and all the other code does not trigger this bug.
I hope that a stack trace will point in the right direction though.

The problem occurs with two different MySQL versions:
mysql  Ver 12.22 Distrib 4.0.20, for pc-linux (i686)
mysql  Ver 14.7 Distrib 4.1.8, for pc-linux (i686)

The problem can be reproduced on two different machines.

I am using PHP 5.0.3. The problem wasn't there with PHP 5.0.2.

PHP was configured like this:
'./configure' '--with-mysql=/usr/local/mysql' '--with-apache=../apache'
'--enable-track-vars' '--with-gettext' '--with-dom' '--with-mcrypt'
'--with-gd' '--with-jpeg-dir' '--with-png-dir' '--with-zlib-dir'
'--with-freetype-dir' '--with-pear' '--enable-mbstring' '--with-iconv'
'--disable-debug' '--enable-soap'


This is a stacktrace of the failure:

# gdb /usr/local/apache/bin/httpd
GNU gdb 2002-04-01-cvs
Copyright 2002 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and
you are
welcome to change it and/or distribute copies of it under certain
conditions.
Type show copying to see the conditions.
There is absolutely no warranty for GDB.  Type show warranty for
details.
This GDB was configured as i386-linux...(no debugging symbols
found)...
(gdb) run -X
Starting program: /usr/local/apache/bin/httpd -X
(no debugging symbols found)...[New Thread 1024 (LWP 31535)]

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 1024 (LWP 31535)]
0x403d61b7 in memcpy () from /lib/libc.so.6
(gdb) bt
#0  0x403d61b7 in memcpy () from /lib/libc.so.6
#1  0x0829a104 in cli_read_rows ()
#2  0x0829b942 in mysql_close ()
#3  0x0829ba50 in mysql_real_query ()
#4  0x0817446e in zif_mysql_client_encoding ()
#5  0x0817460c in zif_mysql_client_encoding ()
#6  0x08174630 in zif_mysql_query ()
#7  0x08113a5a in zend_do_fcall_common_helper ()
#8  0x08114091 in zend_do_fcall_handler ()
#9  0x080fc375 in execute ()
#10 0x08113b42 in zend_do_fcall_common_helper ()
#11 0x08113e99 in zend_do_fcall_by_name_handler ()
#12 0x080fc375 in execute ()
#13 0x08113b42 in zend_do_fcall_common_helper ()
#14 0x08113e99 in zend_do_fcall_by_name_handler ()
#15 0x080fc375 in execute ()
#16 0x08113b42 in zend_do_fcall_common_helper ()
#17 0x08113e99 in zend_do_fcall_by_name_handler ()
#18 0x080fc375 in execute ()
#19 0x08113b42 in zend_do_fcall_common_helper ()
#20 0x08113e99 in zend_do_fcall_by_name_handler ()
#21 0x080fc375 in execute ()
#22 0x08113b42 in zend_do_fcall_common_helper ()
---Type return to continue, or q return to quit---
#23 0x08113e99 in zend_do_fcall_by_name_handler ()
#24 0x080fc375 in execute ()
#25 0x08113b42 in zend_do_fcall_common_helper ()
#26 0x08113e99 in zend_do_fcall_by_name_handler ()
#27 0x080fc375 in execute ()
#28 0x08113b42 in zend_do_fcall_common_helper ()
#29 0x08113e99 in zend_do_fcall_by_name_handler ()
#30 0x080fc375 in execute ()
#31 0x08113b42 in zend_do_fcall_common_helper ()
#32 0x08113e99 in zend_do_fcall_by_name_handler ()
#33 0x080fc375 in execute ()
#34 0x08113b42 in zend_do_fcall_common_helper ()
#35 0x08113e99 in zend_do_fcall_by_name_handler ()
#36 0x080fc375 in execute ()
#37 0x08118cd6 in zend_include_or_eval_handler ()
#38 0x080fc375 in execute ()
#39 0x08113b42 in zend_do_fcall_common_helper ()
#40 0x08113e99 in zend_do_fcall_by_name_handler ()
#41 0x080fc375 in execute ()
#42 0x08118cd6 in zend_include_or_eval_handler ()
#43 0x080fc375 in execute ()
#44 0x08113b42 in zend_do_fcall_common_helper ()
#45 0x08113e99 in zend_do_fcall_by_name_handler ()
---Type return to continue, or q return to quit---
#46 0x080fc375 in execute ()
#47 0x08113b42 in zend_do_fcall_common_helper ()
#48 0x08113e99 in zend_do_fcall_by_name_handler ()
#49 0x080fc375 in execute ()
#50 0x08113b42 in zend_do_fcall_common_helper ()
#51 0x08113e99 in 

#31334 [Opn-Fbk]: phpinfo() bug when refreshed 2/more times. usually at calendar and mail section

2004-12-30 Thread iliaa
 ID:   31334
 Updated by:   [EMAIL PROTECTED]
 Reported By:  nawi2010 at telkom dot net
-Status:   Open
+Status:   Feedback
 Bug Type: *General Issues
 Operating System: Windows XP Prof
 PHP Version:  5.0.3
 New Comment:

Can you provide the broken phpinfo output in a form of an HTML file
somewhere?


Previous Comments:


[2004-12-29 14:31:18] nawi2010 at telkom dot net

Description:

when i execute to test phpinfo() function. the output is get a invalid
character at calendar section and mail parameter.
when i try to refresh the browser the output is different again, and
again. i dont know what it's cause.

i used php with apache 2.0.50 with no ssl support

Reproduce code:
---
phpinfo()






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


#31343 [Com]: Bug on Insert and Update with PHP 5.0.3

2004-12-30 Thread jlim at phplens dot com
 ID:   31343
 Comment by:   jlim at phplens dot com
 Reported By:  iam_simon at hotmail dot com
 Status:   Open
 Bug Type: MSSQL related
 Operating System: Windows 2000 with Apache 1.3.33
 PHP Version:  5.0.3
 New Comment:

Josh Berkus says this is the problem:

FIXED!!

The problem is in the latest implementation of the php_mssql.dll
library for PHP =4.3.10

A bug tracker request has been submitted. For now, the thing to do is
swap out the 4.3.10 php_mssql.dll for 4.3.9 or earlier. I am using the
dll from 4.3.7 and it works. According to the bug tracker, the last
version it worked in was 4.3.9

http://phplens.com/lens/lensforum/msgs.php?id=11403x=1


Previous Comments:


[2004-12-30 20:23:24] liang at saga-city dot com

We have the same problem, 
even after adding the include files. 
The error shows  SQL Execute failed ,
but it actually works and success.



[2004-12-30 05:31:23] iam_simon at hotmail dot com

You need to include() both of the following files from ADODB package:

adodb.inc.php
adodb-errorhandler.inc.php  

The variable $s in adodb-errorhandler.inc.php contains the error
message.



[2004-12-30 05:24:28] iam_simon at hotmail dot com

Description:

I have been using ADODB (a pouplar PHP database wrapper) for several
years and recently I upgraded to PHP 5.0.3 on Apache 1.3.33 with MSSQL.
I got tons error messages from log generated by
adodb-errorhandler.inc.php whenever my app uses INSERT or UPDATE to
the database. There is no problem with SELECT statement.

This is a problem with PHP 5.0.3 only,  5.0.2, 4.0.x or below doesn't
have this problem. 

I contacted author of ADODB, Mr. John Lim said it is a MSSQL/PHP bug,
so I am trying to report this bug here.

Although there is an error, but the row has successfully inserted into
the database.  I am using latest version of Adodb. 


Simon

Reproduce code:
---
$conn = ADONewConnection('mssql'); 
$conn-Connect(hostname, user, pass, dbname); 
$conn-Execute(INSERT INTO visitor_log(date_stamp, ip, host, agent)
Values('2004-12-29 07:10:52PM', '192.168.0.2', '', 'Mozilla/4.0
(compatible; MSIE 6.0; Windows NT 5.1; .NET CLR 1.1.4322)')); 
$conn-Close(); 

Expected result:

mssql error: [0: ] in EXECUTE(INSERT INTO visitor_log(date_stamp, ip,
host, agent) Values('2004-12-29 06:59:18PM', '192.168.0.2', '',
'Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET CLR
1.1.4322)'))

Actual result:
--
no error should be seen





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


#31361 [NEW]: simplexml/domxml segfault when adding node twice

2004-12-30 Thread [EMAIL PROTECTED]
From: [EMAIL PROTECTED]
Operating system: 
PHP version:  5CVS-2004-12-31 (dev)
PHP Bug Type: DOM XML related
Bug description:  simplexml/domxml segfault when adding node twice

Description:

Using the simplexml_add_element function (which uses simplexml/domxml)
produces a segfault when adding a node twice.

Reproduce code:
---
http://rafb.net/paste/results/FuUMWn71.html

Actual result:
--
http://rafb.net/paste/results/tfN2FJ51.html

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


#31360 [Bgs]: Maybe Array operation has some bug

2004-12-30 Thread tokimeki at 1111 dot com dot tw
 ID:   31360
 User updated by:  tokimeki at  dot com dot tw
 Reported By:  tokimeki at  dot com dot tw
 Status:   Bogus
 Bug Type: Arrays related
 Operating System: FreeBSD / Windows XP
 PHP Version:  5.0.3
 New Comment:

I already change the setting (memory_limit = 128M) in php.ini, But it
has the same error.
I think that: $arr is a recursive array, so the operation maybe have
some different!
Notice that, if I remark line 29, and call sohw_var twice, it's ok! So,
this is a error.
Could you tell me, how many memory is enogth?
Thank you!


Previous Comments:


[2004-12-31 03:41:11] [EMAIL PROTECTED]

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

Increase the memory limit, in your code you end up duplicating lot's of
data which causes this limit to be reached.



[2004-12-31 02:40:09] tokimeki at  dot com dot tw

Description:

look the two source, index.php and debug.php.
At index.php (line 29), after array copy, and call show_var to show
$arr or $test, I get a error.


Reproduce code:
---
http://timteam.org/?TIM=FORUMFORUM=1ShowDocument=12961#TIM12961

Expected result:

ok
(array) = {
obj (object) = {}
str (string) = str
arr (array) = {}
number (integer) = 100
bool (boolean) = 1
null (NULL) = 
test (array) = {
AAA (string) = 000
BBB (array) = {
zzz (string) = Z
xxx (array) = {
zzz (string) = Z
xxx (array) - (@[test][BBB][xxx])
}
yyy (array) = {
www (array) - (@[test][BBB])
vvv (array) - (@[test][BBB])
}
}
CCC (array) - (@)
DDD (string) = ABC
EEE (array) - (@[test][BBB][yyy])
FFF (array) - (@[test][BBB])
[EMAIL PROTECTED]*()_+|~`\:;,.? (array) = {
TEST (string) = [EMAIL PROTECTED]*()_+|~`\:;,.?
}
  (array) - (@[test][[EMAIL PROTECTED]*()_+|~`\:;,.?])
}
}



Actual result:
--
ok
Fatal error: Allowed memory size of 8388608 bytes exhausted (tried to
allocate 128 bytes) in /home/tokimeki/public_html/test/debug.php on
line 29





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


#31343 [Opn]: Bug on Insert and Update with PHP 5.0.3

2004-12-30 Thread iam_simon at hotmail dot com
 ID:   31343
 User updated by:  iam_simon at hotmail dot com
 Reported By:  iam_simon at hotmail dot com
 Status:   Open
 Bug Type: MSSQL related
 Operating System: Windows 2000 with Apache 1.3.33
 PHP Version:  5.0.3
 New Comment:

I tried swapping my 5.0.3 dll with 5.0.2 php_mssql.dll in c:\php\ext,
but my Apache didn't start. It said unable to initialize module... 
error.  Any workaround for Php 5.0.3?  or did I do something stupid?


Previous Comments:


[2004-12-31 04:10:46] jlim at phplens dot com

Josh Berkus says this is the problem:

FIXED!!

The problem is in the latest implementation of the php_mssql.dll
library for PHP =4.3.10

A bug tracker request has been submitted. For now, the thing to do is
swap out the 4.3.10 php_mssql.dll for 4.3.9 or earlier. I am using the
dll from 4.3.7 and it works. According to the bug tracker, the last
version it worked in was 4.3.9

http://phplens.com/lens/lensforum/msgs.php?id=11403x=1



[2004-12-30 20:23:24] liang at saga-city dot com

We have the same problem, 
even after adding the include files. 
The error shows  SQL Execute failed ,
but it actually works and success.



[2004-12-30 05:31:23] iam_simon at hotmail dot com

You need to include() both of the following files from ADODB package:

adodb.inc.php
adodb-errorhandler.inc.php  

The variable $s in adodb-errorhandler.inc.php contains the error
message.



[2004-12-30 05:24:28] iam_simon at hotmail dot com

Description:

I have been using ADODB (a pouplar PHP database wrapper) for several
years and recently I upgraded to PHP 5.0.3 on Apache 1.3.33 with MSSQL.
I got tons error messages from log generated by
adodb-errorhandler.inc.php whenever my app uses INSERT or UPDATE to
the database. There is no problem with SELECT statement.

This is a problem with PHP 5.0.3 only,  5.0.2, 4.0.x or below doesn't
have this problem. 

I contacted author of ADODB, Mr. John Lim said it is a MSSQL/PHP bug,
so I am trying to report this bug here.

Although there is an error, but the row has successfully inserted into
the database.  I am using latest version of Adodb. 


Simon

Reproduce code:
---
$conn = ADONewConnection('mssql'); 
$conn-Connect(hostname, user, pass, dbname); 
$conn-Execute(INSERT INTO visitor_log(date_stamp, ip, host, agent)
Values('2004-12-29 07:10:52PM', '192.168.0.2', '', 'Mozilla/4.0
(compatible; MSIE 6.0; Windows NT 5.1; .NET CLR 1.1.4322)')); 
$conn-Close(); 

Expected result:

mssql error: [0: ] in EXECUTE(INSERT INTO visitor_log(date_stamp, ip,
host, agent) Values('2004-12-29 06:59:18PM', '192.168.0.2', '',
'Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET CLR
1.1.4322)'))

Actual result:
--
no error should be seen





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


#31344 [Fbk-Opn]: PHP 4.3.10 crashed Apache without message

2004-12-30 Thread sysadmin at amhosting dot com
 ID:   31344
 User updated by:  sysadmin at amhosting dot com
 Reported By:  sysadmin at amhosting dot com
-Status:   Feedback
+Status:   Open
 Bug Type: Apache2 related
 Operating System: Red Hat 9 + Legacy
 PHP Version:  4.3.10
 New Comment:

I read the indicated page, and it assumes that PHP (and Apache) can get
started in the first place.  That's not my problem.  I'm not the person
to go digging in httpd with gdb, either.

So I'm sorry, there isn't much I can do.  If there is someone reading
these bugs that can do what you request, that would be great.


Previous Comments:


[2004-12-31 01:30:31] [EMAIL PROTECTED]

Thank you for this bug report. To properly diagnose the problem, we
need a backtrace to see what is happening behind the scenes. To
find out how to generate a backtrace, please read
http://bugs.php.net/bugs-generating-backtrace.php

Once you have generated a backtrace, please submit it to this bug
report and change the status back to Open. Thank you for helping
us make PHP better.





[2004-12-30 18:29:27] sysadmin at amhosting dot com

The example script, run in the bash shell, looks something like this
for Red Hat 9:

---start of script---
#!/bin/bash
service httpd start
sleep 3
ps ax | grep httpd
---end of script---

What I expect is to see a number of processes with the name httpd
with PID numbers, all different.

Before PHP install, I get that.

After PHP install, I get grep httpd

Remove PHP from the system, it works again.

Script enough for you?



[2004-12-30 13:39:01] [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 ?php and ends 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 avoid embedding huge scripts into the report.





[2004-12-30 13:22:50] egor at ensita dot net

the latest stable doesn't help. :(



[2004-12-30 08:10:14] [EMAIL PROTECTED]

Please try using this CVS snapshot:

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





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

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


#31362 [NEW]: GtkFileSelection-complete more complete

2004-12-30 Thread ceo at l-i-e dot com
From: ceo at l-i-e dot com
Operating system: 
PHP version:  Irrelevant
PHP Bug Type: Feature/Change Request
Bug description:  GtkFileSelection-complete more complete

Description:

It would be Really Nifty (tm) if GtkFileSelection-complete took an
optional second argument which would make the pattern matching
'pervasive'

IE, the dialog would continue to only present filenames that matched the
given expression.

Providing the same functionality through some other mechanism would be
fine, of course.

I suppose one could, in theory, dig down into the guts of the Widget, and
find all the widgets inside that can affect the selection, and then
connect() a function to each one that would call complete() repeatedly...

But it would be Really Hard for your mere mortal programmer to find *ALL*
the possible circumstances that could change the selection



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


#31360 [Bgs]: Maybe Array operation has some bug

2004-12-30 Thread tokimeki at 1111 dot com dot tw
 ID:   31360
 User updated by:  tokimeki at  dot com dot tw
 Reported By:  tokimeki at  dot com dot tw
 Status:   Bogus
 Bug Type: Arrays related
 Operating System: FreeBSD / Windows XP
 PHP Version:  5.0.3
 New Comment:

I'm sorry! I already find the problem.
That is the serialize function which can't serialize a recursive
array~~~


Previous Comments:


[2004-12-31 04:34:52] tokimeki at  dot com dot tw

I already change the setting (memory_limit = 128M) in php.ini, But it
has the same error.
I think that: $arr is a recursive array, so the operation maybe have
some different!
Notice that, if I remark line 29, and call sohw_var twice, it's ok! So,
this is a error.
Could you tell me, how many memory is enogth?
Thank you!



[2004-12-31 03:41:11] [EMAIL PROTECTED]

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

Increase the memory limit, in your code you end up duplicating lot's of
data which causes this limit to be reached.



[2004-12-31 02:40:09] tokimeki at  dot com dot tw

Description:

look the two source, index.php and debug.php.
At index.php (line 29), after array copy, and call show_var to show
$arr or $test, I get a error.


Reproduce code:
---
http://timteam.org/?TIM=FORUMFORUM=1ShowDocument=12961#TIM12961

Expected result:

ok
(array) = {
obj (object) = {}
str (string) = str
arr (array) = {}
number (integer) = 100
bool (boolean) = 1
null (NULL) = 
test (array) = {
AAA (string) = 000
BBB (array) = {
zzz (string) = Z
xxx (array) = {
zzz (string) = Z
xxx (array) - (@[test][BBB][xxx])
}
yyy (array) = {
www (array) - (@[test][BBB])
vvv (array) - (@[test][BBB])
}
}
CCC (array) - (@)
DDD (string) = ABC
EEE (array) - (@[test][BBB][yyy])
FFF (array) - (@[test][BBB])
[EMAIL PROTECTED]*()_+|~`\:;,.? (array) = {
TEST (string) = [EMAIL PROTECTED]*()_+|~`\:;,.?
}
  (array) - (@[test][[EMAIL PROTECTED]*()_+|~`\:;,.?])
}
}



Actual result:
--
ok
Fatal error: Allowed memory size of 8388608 bytes exhausted (tried to
allocate 128 bytes) in /home/tokimeki/public_html/test/debug.php on
line 29





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


#31363 [NEW]: Non-blocking flock() broken

2004-12-30 Thread ian at snork dot net
From: ian at snork dot net
Operating system: Debian woody (i386)
PHP version:  5.0.3
PHP Bug Type: Filesystem function related
Bug description:  Non-blocking flock() broken

Description:

This code works in PHP 4.3.0, but does not in PHP 5.0.3.

When invoked, it will try to lock /tmp/test1, /tmp/test2  
or /tmp/test3 for exclusive use, whichever is free. If  
none are, it will wait a second before cycling through  
with another attempt.   
   
When running concurrently, the first invocation correctly   
picks up /tmp/test1; the second and subsequent ones just   
cycle forever.   
  
For some reason, the non-blocking flock() only sets $block  
the first time.  

Reproduce code:
---
while (!sleep(1))
  foreach (array(/tmp/test1, /tmp/test2, /tmp/test3) as $path)
if (flock($handle = fopen($path, w), LOCK_EX | LOCK_NB, $block) and
!$block)
{
  echo Got $path\n; 
  sleep(10); 
  echo Releasing $path\n; 
  exit; 
}


Expected result:

$ php5 flock_test.php   
Got /tmp/test1   
$ php5 flock_test.php   
Got /tmp/test2   
$ php5 flock_test.php   
Got /tmp/test3   
$ php5 flock_test.php   
Releasing /tmp/test1  
Got /tmp/test1  
$ 


Actual result:
--
$ php5 flock_test.php  
Got /tmp/test1 
$ php5 flock_test.php  
$ php5 flock_test.php  
$ php5 flock_test.php  
$ 

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


#31355 [Fbk-Opn]: Access Violation at 00BA73CD

2004-12-30 Thread najones3 at vt dot edu
 ID:   31355
 User updated by:  najones3 at vt dot edu
 Reported By:  najones3 at vt dot edu
-Status:   Feedback
+Status:   Open
 Bug Type: Scripting Engine problem
 Operating System: Windows XP
 PHP Version:  5.0.1
 New Comment:

I have a page (search.php) where the user enters the customer number
they wish to view information on. there is no php on this page but when
it loads it shows the access violation at 00BA73CD error at the
bottom.  after the user enters and pushes the search button it opens
results.php, runs the sql query and prints out the information that
cooresponds to the customer number entered.  that page also displays
the access violation at 00BA73CD error at the bottom of it.  that is
all the information i can submit, there are no function calls, the
script is working fine, just displaying this message that i'd like to
get rid of.  thank you


Previous Comments:


[2004-12-30 20:20:24] [EMAIL PROTECTED]

Not enough information was provided for us to be able
to handle this bug. Please re-read the instructions at
http://bugs.php.net/how-to-report.php

If you can provide more information, feel free to add it
to this bug and change the status back to Open.

Thank you for your interest in PHP.




[2004-12-30 16:08:33] najones3 at vt dot edu

Description:

I recently moved from an apache webserver to IIS just because there
were some conflicts.  The php code works fine but now on all my .php
pages there is a generated piece of code at the bottom stating that php
has encountered an access violation at X.  It was not producing
this while running on apache, but i have followed all steps for setting
it up on IIS.  Please help me get rid of this, it is driving me nuts






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


#31360 [Bgs]: Maybe Array operation has some bug

2004-12-30 Thread tokimeki at 1111 dot com dot tw
 ID:   31360
 User updated by:  tokimeki at  dot com dot tw
 Reported By:  tokimeki at  dot com dot tw
 Status:   Bogus
 Bug Type: Arrays related
 Operating System: FreeBSD / Windows XP
 PHP Version:  5.0.3
 New Comment:

I find a solution.
use this function to replace array copy.
ex: $test = clone($arr); // replace $test = $arr;

function  clone($var) {
return $var;
}


Previous Comments:


[2004-12-31 06:03:49] tokimeki at  dot com dot tw

I'm sorry! I already find the problem.
That is the serialize function which can't serialize a recursive
array~~~



[2004-12-31 04:34:52] tokimeki at  dot com dot tw

I already change the setting (memory_limit = 128M) in php.ini, But it
has the same error.
I think that: $arr is a recursive array, so the operation maybe have
some different!
Notice that, if I remark line 29, and call sohw_var twice, it's ok! So,
this is a error.
Could you tell me, how many memory is enogth?
Thank you!



[2004-12-31 03:41:11] [EMAIL PROTECTED]

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

Increase the memory limit, in your code you end up duplicating lot's of
data which causes this limit to be reached.



[2004-12-31 02:40:09] tokimeki at  dot com dot tw

Description:

look the two source, index.php and debug.php.
At index.php (line 29), after array copy, and call show_var to show
$arr or $test, I get a error.


Reproduce code:
---
http://timteam.org/?TIM=FORUMFORUM=1ShowDocument=12961#TIM12961

Expected result:

ok
(array) = {
obj (object) = {}
str (string) = str
arr (array) = {}
number (integer) = 100
bool (boolean) = 1
null (NULL) = 
test (array) = {
AAA (string) = 000
BBB (array) = {
zzz (string) = Z
xxx (array) = {
zzz (string) = Z
xxx (array) - (@[test][BBB][xxx])
}
yyy (array) = {
www (array) - (@[test][BBB])
vvv (array) - (@[test][BBB])
}
}
CCC (array) - (@)
DDD (string) = ABC
EEE (array) - (@[test][BBB][yyy])
FFF (array) - (@[test][BBB])
[EMAIL PROTECTED]*()_+|~`\:;,.? (array) = {
TEST (string) = [EMAIL PROTECTED]*()_+|~`\:;,.?
}
  (array) - (@[test][[EMAIL PROTECTED]*()_+|~`\:;,.?])
}
}



Actual result:
--
ok
Fatal error: Allowed memory size of 8388608 bytes exhausted (tried to
allocate 128 bytes) in /home/tokimeki/public_html/test/debug.php on
line 29





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