#35042 [Opn-Bgs]: new installer lacks everything

2005-11-01 Thread derick
 ID:   35042
 Updated by:   [EMAIL PROTECTED]
 Reported By:  sah1978 at yahoo dot com
-Status:   Open
+Status:   Bogus
 Bug Type: *General Issues
 Operating System: windows
 PHP Version:  5.0.5
 New Comment:

I'm not sure what you're talking about, as our Installers never offered
the full scala of extensions. You need the .zip archive for that.


Previous Comments:


[2005-11-01 08:58:48] sah1978 at yahoo dot com

Description:

Ok here is the dilly.  You guys took out all the dll files and the
extras that used to be packed with php.  It used to be great no hassel.
 Now we need to add all the dlls ourselves then make sure that they are
refferenced in the php.ini then make sure IIS works with them.  WOW i
thought that we wanted to make php popular and let as many ppl use it. 
But, i wonder if in turn you have made it harder to install or easier.

Best solution would be to give an installer with all the extentions (i
mean all the ones that we used to have before the most common ones) and
also give an installer with no extentions.

Thanks






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


#35043 [NEW]: mktime() seems to return odd results for 31st of October

2005-11-01 Thread daniel at septum dot org
From: daniel at septum dot org
Operating system: Linux 2.4
PHP version:  6CVS-2005-11-01 (snap)
PHP Bug Type: Date/time related
Bug description:  mktime() seems to return odd results for 31st of October

Description:

When involving the 31st of October (either by finding out number of days
between 2005-10-29 and 2005-10-31 or 2005-10-31 and 2005-11-01), it gives
the wrong result.

Days between 2005-10-29 and 2005-10-30 returns 1 (which is correct),
however, days between 2005-10-29 and 2005-10-31 returns 3 (which is
incorrect, it should be 2).

It seems to work fine for 2001, 2002, 2003 and 2006-2009, not for 2004 and
2005 (as stated above).

Reproduce code:
---
$dos = 2005-10-30; 

$year = substr($dos, 0, 4);   
$month = substr($dos, 5, 2);   
$day = substr($dos, 8, 2);   

$mktime_dos = mktime(0, 0, 0, $month, $day, $year);   

$next_month = 2005-11-01; 

$year = substr($next_month, 0, 4);   
$month = substr($next_month, 5, 2);   
$day = substr($next_month, 8, 2); 

$mktime_now = mktime(0, 0, 0, $month, $day, $year);   

$difference = $mktime_now - $mktime_dos; 
$signed_up_days_ago = ceil($difference / 60 / 60 / 24); 

echo $signed_up_days_ago . \n;


Expected result:

2

Actual result:
--
3

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


#35044 [NEW]: Segmentation fault

2005-11-01 Thread boris at psyonline dot ru
From: boris at psyonline dot ru
Operating system: Linux 2.6.14-rc2 
PHP version:  5.0.5
PHP Bug Type: Reproducible crash
Bug description:  Segmentation fault

Description:

Server not found. Segmentation fault

Reproduce code:
---
?php
function any_func () { 
   return any_func;
} 

$any_var = any_value;
switch ($any_var) { 
   default:
  class any_class {  
 function any_class_func() {  
   echo any_class_func .any_func().;
 } 
  } 
  
  $any_class = new any_class();
  $any_class-any_class_func(); 
} 
?

Expected result:

any_class_func any_func

Actual result:
--
Server not found. Segmentation fault

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


#35043 [Opn-Bgs]: mktime() seems to return odd results for 31st of October

2005-11-01 Thread derick
 ID:   35043
 Updated by:   [EMAIL PROTECTED]
 Reported By:  daniel at septum dot org
-Status:   Open
+Status:   Bogus
 Bug Type: Date/time related
 Operating System: Linux 2.4
 PHP Version:  6CVS-2005-11-01 (snap)
 New Comment:

We are happy to tell you that you just discovered Daylight Savings
Time. For more information see:
http://webexhibits.org/daylightsaving/b.html
Instead of using mktime/date consider using gmmktime and gmdate which
do
not suffer from DST.

.


Previous Comments:


[2005-11-01 10:58:41] daniel at septum dot org

Description:

When involving the 31st of October (either by finding out number of
days between 2005-10-29 and 2005-10-31 or 2005-10-31 and 2005-11-01),
it gives the wrong result.

Days between 2005-10-29 and 2005-10-30 returns 1 (which is correct),
however, days between 2005-10-29 and 2005-10-31 returns 3 (which is
incorrect, it should be 2).

It seems to work fine for 2001, 2002, 2003 and 2006-2009, not for 2004
and 2005 (as stated above).

Reproduce code:
---
$dos = 2005-10-30; 

$year = substr($dos, 0, 4);   
$month = substr($dos, 5, 2);   
$day = substr($dos, 8, 2);   

$mktime_dos = mktime(0, 0, 0, $month, $day, $year);   

$next_month = 2005-11-01; 

$year = substr($next_month, 0, 4);   
$month = substr($next_month, 5, 2);   
$day = substr($next_month, 8, 2); 

$mktime_now = mktime(0, 0, 0, $month, $day, $year);   

$difference = $mktime_now - $mktime_dos; 
$signed_up_days_ago = ceil($difference / 60 / 60 / 24); 

echo $signed_up_days_ago . \n;


Expected result:

2

Actual result:
--
3





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


#34204 [Opn-Csd]: Apache2s mod_rewrite does not work with PHP5.1.0RC1

2005-11-01 Thread sniper
 ID:   34204
 Updated by:   [EMAIL PROTECTED]
 Reported By:  arpad at zooloo dot com
-Status:   Open
+Status:   Closed
 Bug Type: Apache2 related
 Operating System: Windows XP SP1
 PHP Version:  5.1.0RC4
 New Comment:

Latest CVS checkout of PHP_5_1 branch works fine.



Previous Comments:


[2005-10-31 22:47:37] arpad at zooloo dot com

I recently tried both RC3 and RC4 and both do not work when i'm using
mod_rewrite.
2 Other Bugs report this: 34581 and 34846.
I reverted back to the 200508211030 Nightly which works fine.



[2005-08-21 13:34:24] arpad at zooloo dot com

I tried a recent CVS snapshot and it works. Sorry for the
inconvenience.



[2005-08-21 12:57:35] [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.




[2005-08-21 12:55:28] arpad at zooloo dot com

Description:

With PHP5.1.0RC1 my Apache2 mod_rewrite crashes everytime i want to use
it. It worked fine with PHP5.1.0b3 though.

Reproduce code:
---
RewriteEngine on

RewriteRule index.html index.php

Expected result:

it should display index.html as it was index.php

Actual result:
--
Server crashes with the following log entry:
[notice] Parent: child process exited with status 3221225477 --
Restarting.





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


#32935 [Opn-Fbk]: SNMP timeouts on specific OIDs and truncating of certain OID return strings

2005-11-01 Thread sniper
 ID:   32935
 Updated by:   [EMAIL PROTECTED]
 Reported By:  nospam-php at homeuseonly dot co dot uk
-Status:   Open
+Status:   Feedback
 Bug Type: SNMP related
 Operating System: Windows 2003 SP1 / Windows XP SP
 PHP Version:  5CVS-2005-07-29
 New Comment:

Do you happen to have any of the magic_quotes_* ini settings 'On' when
this happens?



Previous Comments:


[2005-10-14 14:27:12] pawelgl at interia dot pl

I have the same problem with php 4.3.10.
It looks that problem is related to number of backslashes \. It looks
like inside conversion unwind \ into \\ not changing size of string
array. During return conversion all \\ are winded into \ but trailing
chars are lost.



[2005-07-29 18:34:34] nospam-php at homeuseonly dot co dot uk

I have upgraded to the Windows CVS snapshot, but I am still getting
truncated output.

?php
print_R(snmpwalk(192.168.253.10,public,
.1.3.6.1.2.1.25.4.2.1.4));
?

gives me:
Array ( [0] =  [1] =  [2] = C:\\WINDOWS [3] = C:\\Program
Files\\Microsoft Office\\OFFICE [4] = \\SystemRoot\\System3 [5] =
C:\\WINDOWS\\system3 [6] =  [7] = C:\\WINDOWS\\system3 [8] =
C:\\WINDOWS\\system3 [9] = C:\\WINDOWS\\system3 [10] =
C:\\WINDOWS\\system3 [11] = C:\\WINDOWS\\System3 [12] =
C:\\WINDOWS\\system3 [13] = C:\\WINDOWS\\System3 [14] =
C:\\PROGRA~1\\Grisoft\\AV [15] = C:\\WINDOWS\\system3 [16] =
C:\\WINDOWS\\system3 [17] = C:\\PROGRA~1\\Grisoft\\AV [18] =
C:\\Program Files\\Alcohol Soft\\Alcohol 1 [19] = C:\\WINDOWS\
.SNIP



[2005-05-03 23:24:35] nospam-php at homeuseonly dot co dot uk

Description:

When running making specific SNMP get/walks against Windows 2003 or
Windows XP the following has been seen to occur

1.  Sometimes the SNMP walk against .1.3.6.1.2.1.25.2.3 the request
times out.  If I use GetIf to walk the OID the results are displayed,
but PHP fails randomly

2.  When viewing .1.3.6.1.2.1.25.4.2.1.4 with GetIf the file
paths/names are displayed in full, but when I do a SNMP walk the output
is truncated.




Reproduce code:
---
The code can be downloaded from 
http://sourceforge.net/users/lsms-mrtg/

The example windows code is in the package.

Example of the truncated output

?php
print_R(snmpwalk(127.0.0.1,public, .1.3.6.1.2.1.25.4.2.1.4));

?

Expected result:

The full program paths displayed, where appropriate.


Actual result:
--
Array ( [0] =  [1] =  [2] = C:\\Program Files\\Promise
Technology, Inc.\\Promise Array Manageme [3] =  [4] =  [5] =
C:\\users\\isms\\l [6] =  [7] = C:\\WINDOWS\\System3 [8] =
C:\\users\\isms\\l [9] = \\SystemRoot\\System3 [10] =  [11] =
c:\\squid\\sbi [12] = C:\\WINDOWS\\system3 [13] =  [14] =
C:\\WINDOWS\\system3 [15] = C:\\WINDOWS\\System3 [16] =
C:\\WINDOWS\\system3 [17] = C:\\WINDOWS\\system3 [18] =
C:\\WINDOWS\\system3 [19] = C:\\users\\isms\\l [20] = C:\\FS3
[21] =  [22] =  [23] =  [24] =  [25] =
C:\\WINDOWS\\System3 [26] = C:\\WINDOWS\\system3 [27] =
C:\\WINDOWS\\system3 [28] =  [29] = C:\\Program
Files\\TightVNC-unstabl [30] = C:\\PROGRA~1\\Grisoft\\AV [31] =
C:\\users\\isms\\l [32] = C:\\Program Files\\Apache
Group\\Apache2\\ [33] =  [34] = C:\\PROGRA~1\\Grisoft\\AV [35]
= C:\\Program Files\\Promise Technology, Inc\\Promise Array Manageme
[36] = C:\\PROGRA~1\\Grisoft\\AV [37] = C:\\WINDOWS\\system3 [38]
= C:\\users\\isms\\l [39] =  [40] = C:\\WINDOWS\\System3 [41]
= C:\\users\\isms\\l [42] =  [43] = C:\\FS3 [44] =
C:\\users\\isms\\l [45] =  [46] = C:\\Program Files\\Promise
Technology, Inc.\\Promise Array Manageme [47] =  [48] =
C:\\WINDOWS [49] =  [50] = C:\\PROGRA~1\\Grisoft\\AV [51] =
C:\\WINDOWS [52] = C:\\Program Files\\ASUS\\Pro [53] =
C:\\WINDOWS\\system3 [54] = C:\\Program Files\\ATI
Technologies\\ATI Control Pan [55] =  [56] =  [57] =
C:\\WINDOWS\\system32\\wb [58] = C:\\Program Files\\Apache
Group\\Apache2\\ [59] = C:\\FS3 [60] =  [61] =
C:\\PROGRA~1\\HAUPPA~ [62] =  [63] =
C:\\PROGRA~1\\HAUPPA~1\\Hardwa [64] =  [65] = C:\\Program
Files\\Apache Group\\Apache2\\ [66] =
C:\\PROGRA~1\\HAUPPA~1\\Hardwa [67] =  [68] =
C:\\WINDOWS\\system3 [69] =  ) 





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


#31453 [Ver-Fbk]: array_rand() is not returning random values

2005-11-01 Thread sniper
 ID:   31453
 Updated by:   [EMAIL PROTECTED]
 Reported By:  cdturri at hotmail dot com
-Status:   Verified
+Status:   Feedback
 Bug Type: Arrays related
 Operating System: win32 only
 PHP Version:  5CVS, 4CVS (2005-01-10)
 New Comment:

Please try using this CVS snapshot:

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




Previous Comments:


[2005-01-11 00:54:33] [EMAIL PROTECTED]

I can't reproduce this with Apache2-worker either so it's not ZTS
problem. Just some weird windows bug again.




[2005-01-10 23:53:49] cdturri at hotmail dot com

OK, done my homework. Tested under IIS and Apache on Windows with the
CVS builds provided by sniper (PHP4). Bug appeared on BOTH cases. Here
are the headers:

 2 Server: Microsoft-IIS/5.0
 3 Date: Mon, 10 Jan 2005 22:45:26 GMT
 4 X-Powered-By: ASP.NET
 6 X-Powered-By: PHP/4.3.11-dev

And:

 2 Date: Mon, 10 Jan 2005 22:49:21 GMT
 3 Server: Apache/2.0.52 (Win32) PHP/4.3.11-dev
 4 X-Powered-By: PHP/4.3.11-dev

As my previous comment I saw no needs to test it under PHP4 with the
latest CVS builds in Linux since the bug did not appear on PHP 4.3.9
under Linux. So, we have nailed down the issue to this:

- Bug appears on a Windows System running either IIS or Apache. 
- Bug appears on both PHP4 and PHP5 latest CVS builds. 

Couple of more findings:

- The first key that array_rand() returns on the first run after the
Web Server is restarted seems to be random.
- Decreasing the number of keys on the INI file seems to increase the
subset of keys that array_rand() incorrectly returns as random keys. 
- Inversely, increasing the number of keys on the INI file seems to
decrease the subset of keys that array_rand() incorrectly returns as
random keys.

All yours guys!



[2005-01-10 22:28:57] cdturri at hotmail dot com

Hi,

Tested under IIS 5.0 and the bug is indeed present. Headers:

 1 HTTP/1.1 200 OK
 2 Server: Microsoft-IIS/5.0
 3 Date: Mon, 10 Jan 2005 21:36:20 GMT
 4 X-Powered-By: ASP.NET
 5 Content-type: text/html
 6 X-Powered-By: PHP/5.0.3

Thanks,
Christian



[2005-01-10 22:20:05] [EMAIL PROTECTED]

Also, is this a Windows-only problem with ZTS? Because apparently, it
works under Apache 2 on Linux without a problem. Can someone reproduce
this bug on anything but Win32? Is this limited to Apache2, or is it
present in IIS as well?



[2005-01-10 22:04:06] [EMAIL PROTECTED]

Present in my Web configuration.
http://jed.homedns.org/test.php

Apache/2.0.52, PHP/5.0.3
Microsoft Windows XP [Version 5.1.2600]

However, *NOT* present in command line. (ZTS?)



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

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


#27678 [Ver-Asn]: number_format() crashes with large numbers.

2005-11-01 Thread sniper
 ID:   27678
 Updated by:   [EMAIL PROTECTED]
 Reported By:  morten_odegaard at broadpark dot no
-Status:   Verified
+Status:   Assigned
 Bug Type: Math related
 Operating System: *
 PHP Version:  5CVS, 4CVS (2005-08-19)
-Assigned To:  
+Assigned To:  helly
 New Comment:

Marcus, can you check this out please?


Previous Comments:


[2005-03-30 10:58:49] kameshj at fastmail dot fm

Regarding the segfault,
In main/snprintf.c:ap_php_cvt has a call to memmove(buf[mvl], buf[0],
NDIG-mvl-1); NDIG-mvl-1 becomes -1 in the mentioned defect of double
being 1e80, decimals 3, dec_sep '' and thousand_sep ' '.
As I could see php recognizes a float as hight as 1e308, I feel NDIG
should be set accordingly to higher value let us say 310 or 311.



[2004-12-12 23:52:48] [EMAIL PROTECTED]

(gdb) run -r echo number_format(1e80, 3, '', ' ');
Starting program: /www/php-modules/bin/php -r echo number_format(1e80,
3, '', ' ');
[New Thread 1087948032 (LWP 31942)]

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 1087948032 (LWP 31942)]
0x4207c0ad in memmove () from /lib/tls/libc.so.6
(gdb) bt
#0  0x4207c0ad in memmove () from /lib/tls/libc.so.6
#1  0xbfffd8e8 in ?? ()
#2  0x08259347 in ap_php_cvt (arg=Cannot access memory at address
0xffef
) at /usr/src/web/php/php4/main/snprintf.c:294
Cannot access memory at address 0x




[2004-03-24 14:27:01] morten_odegaard at broadpark dot no

Description:

number_format() seems to be having problems with large numbers. I've
found two different bugs, where one can segfault Apache.
They are tested on both 4.3.4 and 5.0RC1 on Linux, and 4.3.4 on
Windows. Bugs happens in all of them.

--

Calling the function on numbers higher than (and including) 1e71, it
will display a wrong result. Some numbers will have one 0 replaced with
a 7, while some will be a digit too short, but be very close to the
number it is supposed to show.

--

When calling number_format() on numbers bigger than (and including)
1e80, it will either return nothing or crash, depending on the
'decimals' parameter.

If 'decimals' is bigger then 0, then it will return nothing.

If 'decimals' is lower then 1, Apache will segfault.

Reproduce code:
---
$ php -r echo number_format(1e71, 0, '', ' ');
100 000 000 000 000 070 000 000 000 000 000 000 000 000 000 000 000 000
000 000 000 000 000 000

$ php -r echo number_format(1e72, 0, '', ' ');
999 999 999 999 999 600 000 000 000 000 000 000 000 000 000 000 000 000
000 000 000 000 000 000


$ php -r echo number_format(1e80, 3, '', ' ');
$ php -r echo number_format(1e80, 0, '', ' ');
Segmentation fault

Expected result:

100 000 000 000 000 000 000 000 000 000 000 000 000 000 000 000 000 000
000 000 000 000 000 000

1 000 000 000 000 000 000 000 000 000 000 000 000 000 000 000 000 000
000 000 000 000 000 000 000


10 000 000 000 000 000 000 000 000 000 000 000 000 000 000 000 000 000
000 000 000 000 000 000 000 000 000.000

10 000 000 000 000 000 000 000 000 000 000 000 000 000 000 000 000 000
000 000 000 000 000 000 000 000 000

Actual result:
--
Bug 1: Wrong numbers, as shown above.
Bug 2: Nothing or a segfault, as show above.





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


#35013 [Opn]: bad passing of header to get sender's email address

2005-11-01 Thread sniper
 ID:   35013
 Updated by:   [EMAIL PROTECTED]
 Reported By:  php-louis at steelbytes dot com
 Status:   Open
 Bug Type: Mail related
 Operating System: win2003
 PHP Version:  5CVS-2005-10-31 (snap)
 New Comment:

See bug #28038, this is just one more case related to that.



Previous Comments:


[2005-10-31 01:41:24] php-louis at steelbytes dot com

still does it.  what did you change? anything? or were you just wanting
to findout if it happens in the curretn snapshot as apposed to last
releasse ver?



[2005-10-31 01:27:00] [EMAIL PROTECTED]

Please try using this CVS snapshot:

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





[2005-10-29 03:46:45] php-louis at steelbytes dot com

Description:

when mail() is passing the headers to get the sender's email address
and the headers are similar to the following:
  To: blah
  From: [EMAIL PROTECTED]
  AnotherHeader: value
it retrieves  [EMAIL PROTECTED] as the senders email, instead of
[EMAIL PROTECTED].  this is a problem when sending email to yahoo, as
the MAIL FROM smtp command that mail() generates looks like the
following:
  MAIL FROM: [EMAIL PROTECTED]
instead of 
  MAIL FROM:[EMAIL PROTECTED]
or
  MAIL FROM: [EMAIL PROTECTED]
and yahoo rejects.


Reproduce code:
---
mail('[EMAIL PROTECTED]','test subject','test body','From:
[EMAIL PROTECTED]');

Expected result:

yahoo rejects with the following
  501 Syntax error in parameters or arguments


Actual result:
--
n/a





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


#35013 [Opn-Bgs]: bad passing of header to get sender's email address

2005-11-01 Thread sniper
 ID:   35013
 Updated by:   [EMAIL PROTECTED]
 Reported By:  php-louis at steelbytes dot com
-Status:   Open
+Status:   Bogus
 Bug Type: Mail related
 Operating System: win2003
 PHP Version:  5CVS-2005-10-31 (snap)
 New Comment:

.


Previous Comments:


[2005-11-01 11:35:27] [EMAIL PROTECTED]

See bug #28038, this is just one more case related to that.




[2005-10-31 01:41:24] php-louis at steelbytes dot com

still does it.  what did you change? anything? or were you just wanting
to findout if it happens in the curretn snapshot as apposed to last
releasse ver?



[2005-10-31 01:27:00] [EMAIL PROTECTED]

Please try using this CVS snapshot:

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





[2005-10-29 03:46:45] php-louis at steelbytes dot com

Description:

when mail() is passing the headers to get the sender's email address
and the headers are similar to the following:
  To: blah
  From: [EMAIL PROTECTED]
  AnotherHeader: value
it retrieves  [EMAIL PROTECTED] as the senders email, instead of
[EMAIL PROTECTED].  this is a problem when sending email to yahoo, as
the MAIL FROM smtp command that mail() generates looks like the
following:
  MAIL FROM: [EMAIL PROTECTED]
instead of 
  MAIL FROM:[EMAIL PROTECTED]
or
  MAIL FROM: [EMAIL PROTECTED]
and yahoo rejects.


Reproduce code:
---
mail('[EMAIL PROTECTED]','test subject','test body','From:
[EMAIL PROTECTED]');

Expected result:

yahoo rejects with the following
  501 Syntax error in parameters or arguments


Actual result:
--
n/a





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


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

2005-11-01 Thread sniper
 ID:   28038
 Updated by:   [EMAIL PROTECTED]
 Reported By:  jordi at jcanals dot net
 Status:   Open
 Bug Type: Mail related
 Operating System: win32
 PHP Version:  5CVS, 4CVS (2005-08-08)
 New Comment:

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




Previous Comments:


[2005-08-08 00:14:40] [EMAIL PROTECTED]

See also: #32600 (rpath set wrong too)




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

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

RCPT TO:[EMAIL PROTECTED] 

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

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




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

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

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

Full file:

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

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



[2004-04-17 19:14:01] jordi at jcanals dot net

Description:

In windows, and using an SMTP server, when you try to send a mail using
the mail function the SMTP transaction will fail if you include
recipient names.

When including any recipient header in the following format (wich
follows the RFC 2822), the mail function does not handle it properly:

To: User Name [EMAIL PROTECTED]
Cc: Other User [EMAIL PROTECTED]
Bcc: Third User [EMAIL PROTECTED]

Loking at the SMTP transaction, the PHP mail layer sends this RCPT
commands wich do not folow the SMTP standard stated on RFC 2821:

RCPT TO:User Name [EMAIL PROTECTED]
RCPT TO:Other User [EMAIL PROTECTED]
RCPT TO:Third User [EMAIL PROTECTED]

Fails always with this environments:
Tested on Windows XP, Apache 2.0.49, PHP 4.3.6 (Also in 4.3.4)
Tested also on Windows 2000, IIS, PHP 4.3.6

Tested Using SMTP servers on Linux with Exim and Sendmail.
Tested also using the default Windows 2000 SMTP server.

Reproduce code:
---
// SAMPLE 1:

$to_recipient = User Name [EMAIL PROTECTED];
$header = Cc: Other User [EMAIL PROTECTED]\r\n;
$header .= Bcc: Third User [EMAIL PROTECTED]\r\n;
mail($to_recipient, $subject, $body, $header);

// FAILS with SMTP errors for all three recipients.

SAMPLE 2:
$to_recipient = [EMAIL PROTECTED];
$header = To: User Name [EMAIL PROTECTED]\r\n;
$header .= Cc: Other User [EMAIL PROTECTED]\r\n;
$header .= Bcc: Third User [EMAIL PROTECTED]\r\n;
mail($to_recipient, $subject, $body, $header);

FAILS on with SMTP error on the three recipients passed on the $header
field.

Expected result:

Expected that the mail layer exctracts only the mail address from
recipients to send the SMTP commands:

As seen on the RFC's 2821 and 2822, when sending a mail with the
recipient headers formed like above, it is expected the mail layer to
extract ONLY the email address to send the RCPT commands, and pass the
headers without any change in the DATA command during the SMTP
transaction. Example of the  correct SMTP transaction for the above
headers:

RCPT TO:[EMAIL PROTECTED]
RCPT TO:[EMAIL PROTECTED]
RCPT TO:[EMAIL PROTECTED]

DATA

To: User Name [EMAIL PROTECTED]
Cc: Other User [EMAIL PROTECTED]
Bcc: Third User [EMAIL PROTECTED]


Actual result:
--
You get that error for all recipients with the recipient name:

Warning: mail(): SMTP server response: 501 SomeOne Name
[EMAIL PROTECTED]: @ or . expected after SomeOne in
mail.class.php on line 333

This error is produced when the mail layer is sending a wrong formed
RCPT TO: command in the SMTP transaction.





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


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

2005-11-01 Thread sniper
 ID:   28038
 Updated by:   [EMAIL PROTECTED]
 Reported By:  jordi at jcanals dot net
 Status:   Open
 Bug Type: Mail related
 Operating System: win32
 PHP Version:  5CVS, 4CVS (2005-08-08)
 New Comment:

See also bug #32600 (rpath set wrong too)


Previous Comments:


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

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





[2005-08-08 00:14:40] [EMAIL PROTECTED]

See also: #32600 (rpath set wrong too)




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

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

RCPT TO:[EMAIL PROTECTED] 

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

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




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

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

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

Full file:

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

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



[2004-04-17 19:14:01] jordi at jcanals dot net

Description:

In windows, and using an SMTP server, when you try to send a mail using
the mail function the SMTP transaction will fail if you include
recipient names.

When including any recipient header in the following format (wich
follows the RFC 2822), the mail function does not handle it properly:

To: User Name [EMAIL PROTECTED]
Cc: Other User [EMAIL PROTECTED]
Bcc: Third User [EMAIL PROTECTED]

Loking at the SMTP transaction, the PHP mail layer sends this RCPT
commands wich do not folow the SMTP standard stated on RFC 2821:

RCPT TO:User Name [EMAIL PROTECTED]
RCPT TO:Other User [EMAIL PROTECTED]
RCPT TO:Third User [EMAIL PROTECTED]

Fails always with this environments:
Tested on Windows XP, Apache 2.0.49, PHP 4.3.6 (Also in 4.3.4)
Tested also on Windows 2000, IIS, PHP 4.3.6

Tested Using SMTP servers on Linux with Exim and Sendmail.
Tested also using the default Windows 2000 SMTP server.

Reproduce code:
---
// SAMPLE 1:

$to_recipient = User Name [EMAIL PROTECTED];
$header = Cc: Other User [EMAIL PROTECTED]\r\n;
$header .= Bcc: Third User [EMAIL PROTECTED]\r\n;
mail($to_recipient, $subject, $body, $header);

// FAILS with SMTP errors for all three recipients.

SAMPLE 2:
$to_recipient = [EMAIL PROTECTED];
$header = To: User Name [EMAIL PROTECTED]\r\n;
$header .= Cc: Other User [EMAIL PROTECTED]\r\n;
$header .= Bcc: Third User [EMAIL PROTECTED]\r\n;
mail($to_recipient, $subject, $body, $header);

FAILS on with SMTP error on the three recipients passed on the $header
field.

Expected result:

Expected that the mail layer exctracts only the mail address from
recipients to send the SMTP commands:

As seen on the RFC's 2821 and 2822, when sending a mail with the
recipient headers formed like above, it is expected the mail layer to
extract ONLY the email address to send the RCPT commands, and pass the
headers without any change in the DATA command during the SMTP
transaction. Example of the  correct SMTP transaction for the above
headers:

RCPT TO:[EMAIL PROTECTED]
RCPT TO:[EMAIL PROTECTED]
RCPT TO:[EMAIL PROTECTED]

DATA

To: User Name [EMAIL PROTECTED]
Cc: Other User [EMAIL PROTECTED]
Bcc: Third User [EMAIL PROTECTED]


Actual result:
--
You get that error for all recipients with the recipient name:

Warning: mail(): SMTP server response: 501 SomeOne Name
[EMAIL PROTECTED]: @ or . expected after SomeOne in
mail.class.php on line 333

This error is produced when the mail layer is sending a wrong formed
RCPT TO: command in the SMTP transaction.





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


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

2005-11-01 Thread sniper
 ID:   28038
 Updated by:   [EMAIL PROTECTED]
 Reported By:  jordi at jcanals dot net
 Status:   Open
 Bug Type: Mail related
 Operating System: win32
 PHP Version:  5CVS, 4CVS (2005-08-08)
 New Comment:

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


Previous Comments:


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

See also bug #32600 (rpath set wrong too)



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

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





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

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

RCPT TO:[EMAIL PROTECTED] 

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

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




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

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

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

Full file:

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

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



[2004-04-17 19:14:01] jordi at jcanals dot net

Description:

In windows, and using an SMTP server, when you try to send a mail using
the mail function the SMTP transaction will fail if you include
recipient names.

When including any recipient header in the following format (wich
follows the RFC 2822), the mail function does not handle it properly:

To: User Name [EMAIL PROTECTED]
Cc: Other User [EMAIL PROTECTED]
Bcc: Third User [EMAIL PROTECTED]

Loking at the SMTP transaction, the PHP mail layer sends this RCPT
commands wich do not folow the SMTP standard stated on RFC 2821:

RCPT TO:User Name [EMAIL PROTECTED]
RCPT TO:Other User [EMAIL PROTECTED]
RCPT TO:Third User [EMAIL PROTECTED]

Fails always with this environments:
Tested on Windows XP, Apache 2.0.49, PHP 4.3.6 (Also in 4.3.4)
Tested also on Windows 2000, IIS, PHP 4.3.6

Tested Using SMTP servers on Linux with Exim and Sendmail.
Tested also using the default Windows 2000 SMTP server.

Reproduce code:
---
// SAMPLE 1:

$to_recipient = User Name [EMAIL PROTECTED];
$header = Cc: Other User [EMAIL PROTECTED]\r\n;
$header .= Bcc: Third User [EMAIL PROTECTED]\r\n;
mail($to_recipient, $subject, $body, $header);

// FAILS with SMTP errors for all three recipients.

SAMPLE 2:
$to_recipient = [EMAIL PROTECTED];
$header = To: User Name [EMAIL PROTECTED]\r\n;
$header .= Cc: Other User [EMAIL PROTECTED]\r\n;
$header .= Bcc: Third User [EMAIL PROTECTED]\r\n;
mail($to_recipient, $subject, $body, $header);

FAILS on with SMTP error on the three recipients passed on the $header
field.

Expected result:

Expected that the mail layer exctracts only the mail address from
recipients to send the SMTP commands:

As seen on the RFC's 2821 and 2822, when sending a mail with the
recipient headers formed like above, it is expected the mail layer to
extract ONLY the email address to send the RCPT commands, and pass the
headers without any change in the DATA command during the SMTP
transaction. Example of the  correct SMTP transaction for the above
headers:

RCPT TO:[EMAIL PROTECTED]
RCPT TO:[EMAIL PROTECTED]
RCPT TO:[EMAIL PROTECTED]

DATA

To: User Name [EMAIL PROTECTED]
Cc: Other User [EMAIL PROTECTED]
Bcc: Third User [EMAIL PROTECTED]


Actual result:
--
You get that error for all recipients with the recipient name:

Warning: mail(): SMTP server response: 501 SomeOne Name
[EMAIL PROTECTED]: @ or . expected after SomeOne in
mail.class.php on line 333

This error is produced when the mail layer is sending a wrong formed
RCPT TO: command in the SMTP transaction.





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


#35037 [Opn-Asn]: unknown data type (36)

2005-11-01 Thread sniper
 ID:   35037
 Updated by:   [EMAIL PROTECTED]
 Reported By:  spooky at int13h dot com
-Status:   Open
+Status:   Assigned
 Bug Type: MSSQL related
 Operating System: FreeBSD 5.4
 PHP Version:  5CVS-2005-10-31 (snap)
-Assigned To:  
+Assigned To:  fmk
 New Comment:

Frank, can you check this out please?



Previous Comments:


[2005-10-31 18:11:49] spooky at int13h dot com

Description:

For php5-200510311530 (Also 5.0.5 stable release)

./configure --prefix=/usr/local --with-apxs=/usr/local/apache/bin/apxs
--with-libxml-dir=/usr/local 
--with-zlib 
--with-curl 
--with-gd 
--with-ldap 
--with-mssql
--with-pear

For FreeTDS 0.63 
./configure --prefix=/usr/local 
--with-tdsver=8.0
--enable-msdblib

When I fire an SQL Query that returns a uniqueidentifier I get the
error 'Warning: mssql_query() [function.mssql-query]: column 1 has
unknown data type (36) in /usr/websites/dev/testies.php on line 12'

Reproduce code:
---
function connect_sql ()
{
   $mssql_link = mssql_connect('IP', 'USER','PASSWORD') or die
(Server Connection Error);
   $mssql_db = mssql_select_db('Websites',$mssql_link) or die(Database
Error);
}

connect_sql();

$query = 'select newid() as test';
echo $query . 'br/';
mssql_query($query);
mssql_close();

Expected result:

No result should be returned. It should generate a new id.

Actual result:
--
'Warning: mssql_query() [function.mssql-query]: column 1 has unknown
data type (36) in /usr/websites/dev/testies.php on line 12'





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


#35009 [Opn-Fbk]: mysql_pconnect() crashes on PHP-CLI when ZTS is enabled

2005-11-01 Thread sniper
 ID:   35009
 Updated by:   [EMAIL PROTECTED]
 Reported By:  glen at delfi dot ee
-Status:   Open
+Status:   Feedback
 Bug Type: MySQL related
 Operating System: PLD Linux
 PHP Version:  5CVS-2005-10-28 (snap)
 New Comment:

What if you configure the mysql extension as static, does it work then?


Previous Comments:


[2005-10-28 20:49:51] glen at delfi dot ee

same thing with php5-200510281630

$ ./sapi/cli/php -v
PHP 5.1.0RC5-dev (cli) (built: Oct 28 2005 21:47:13) (DEBUG)
Copyright (c) 1997-2005 The PHP Group
Zend Engine v2.1.0-dev, Copyright (c) 1998-2005 Zend Technologies

$ ./sapi/cli/php  -r 'dl(mysql.so); mysql_pconnect();'

Warning: mysql_pconnect(): Can't connect to local MySQL server through
socket '/var/lib/mysql/mysql.sock' (2) in Command line code on line 1
/home/builder/rpm/BUILD/php5-200510281630/Zend/zend_hash.c(678) :
ht=0x8264d78 is already destroyed
/home/builder/rpm/BUILD/php5-200510281630/Zend/zend_hash.c(678) :
ht=0x8264d78 is already destroyed
/home/builder/rpm/BUILD/php5-200510281630/Zend/zend_hash.c(67) : Bailed
out without a bailout address!
$



[2005-10-28 19:54:46] [EMAIL PROTECTED]

Please try using this CVS snapshot:

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





[2005-10-28 19:08:22] glen at delfi dot ee

ok. this is quick way to see it, altho the error is different.

$ ./configure --disable-all --with-mysql=shared --enable-maintainer-zts
--enable-debug
$ make
$ ./sapi/cli/php  -i |grep -i safe
$ sudo mkdir -p /usr/local/lib/php/extensions/debug-zts-20041030/
$ sudo chown builder /usr/local/lib/php/extensions/debug-zts-20041030/
$ cp modules/mysql.so
/usr/local/lib/php/extensions/debug-zts-20041030/
$ ./sapi/cli/php  -r 'dl(mysql.so); mysql_pconnect();'
Warning: mysql_pconnect(): Can't connect to local MySQL server through
socket '/var/lib/mysql/mysql.sock' (2) in Command line code on line 1
/home/builder/rpm/BUILD/p/php5-STABLE-200510281434/Zend/zend_hash.c(678)
: ht=0x9ce4a74 is already destroyed
/home/builder/rpm/BUILD/p/php5-STABLE-200510281434/Zend/zend_hash.c(678)
: ht=0x9ce4a74 is already destroyed
/home/builder/rpm/BUILD/p/php5-STABLE-200510281434/Zend/zend_hash.c(67)
: Bailed out without a bailout address!
$



[2005-10-28 19:05:48] glen at delfi dot ee

Description:

$ php -r 'mysql_pconnect();'
Segmentation fault

you will need to specify proper auth strings for the connection to
succeed.

bug is present in php 4.4.0, php 5.0.5 with both ZTS enabled. on same
system disabling ZTS with php 4.4.0 the crash didn't occour.

also used php5-STABLE-200510281434 snapshot. and crash was
reproducible.


Reproduce code:
---
$ gdb --args php -r 'mysql_pconnect();'
GNU gdb 6.3
Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and
you are
welcome to change it and/or distribute copies of it under certain
conditions.
Type show copying to see the conditions.
There is absolutely no warranty for GDB.  Type show warranty for
details.
This GDB was configured as --host= --target=i686-pld-linux...Using
host libthread_db library /lib/tls/libthread_db.so.1.

(gdb) run
Starting program: /usr/bin/php -r mysql_pconnect\(\)\;

Program received signal SIGSEGV, Segmentation fault.
0xb7879948 in ?? ()
(gdb) bt
#0  0xb7879948 in ?? ()
#1  0xb7f0d549 in plist_entry_destructor (ptr=0x80dbb00)
at
/home/builder/rpm/BUILD/php5-STABLE-200510281434/Zend/zend_list.c:210
#2  0xb7f0b53f in zend_hash_apply_deleter (ht=0x8052c60, p=0x80e3f40)
at
/home/builder/rpm/BUILD/php5-STABLE-200510281434/Zend/zend_hash.c:574
#3  0xb7f0b790 in zend_hash_graceful_reverse_destroy (ht=0x8052c60)
at
/home/builder/rpm/BUILD/php5-STABLE-200510281434/Zend/zend_hash.c:640
#4  0xb7f0d665 in zend_destroy_rsrc_list (ht=0x8052c60,
tsrm_ls=0x804f0a8)
at
/home/builder/rpm/BUILD/php5-STABLE-200510281434/Zend/zend_list.c:240
#5  0xb7f0146a in zend_shutdown (tsrm_ls=0x804f0a8) at
/home/builder/rpm/BUILD/php5-STABLE-200510281434/Zend/zend.c:714
#6  0xb7eaa3e3 in php_module_shutdown (tsrm_ls=0x804f0a8)
at
/home/builder/rpm/BUILD/php5-STABLE-200510281434/main/main.c:1529
#7  0x0804be44 in main (argc=3, argv=0xbfcb04a4)
at
/home/builder/rpm/BUILD/php5-STABLE-200510281434/sapi/cli/php_cli.c:1058
(gdb)






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


#34978 [Opn-Asn]: php out of memory or segmentation fault while installing sugarcrm 3.5.1a

2005-11-01 Thread sniper
 ID:   34978
 Updated by:   [EMAIL PROTECTED]
 Reported By:  cdc at ccicon dot com
-Status:   Open
+Status:   Assigned
-Bug Type: Reproducible crash
+Bug Type: Scripting Engine problem
 Operating System: linux i386
 PHP Version:  5CVS-2005-10-31 (snap)
-Assigned To:  
+Assigned To:  dmitry
 New Comment:

This is really critical issue. Obviously that stupid compatibility
mode misbehaves still?


Previous Comments:


[2005-10-27 19:10:23] cdc at ccicon dot com

The zend.ze_compatiblity_mode is set to 1 in the index.php file and
several other files using the following test for php version number

if (substr(phpversion(), 0, 1) == 5) {
ini_set(zend.ze1_compatibility_mode, 1);
}

Disabling this option (ie zend.ze_compatiblity_mode=0) under php 5.0.5
and under the last cvs snapshot that was recommended seems to solve
this race condition.  I have not tested the code fully to see that this
hasn't introduced other problems.  However, it does remove the out of
memory and segfault problems.

Were there changes made in php 5.0.5 and later that make this option
obsolete.  Or, will disabling this condition lead to other compatility
issues?

TTYL
  CDC



[2005-10-27 18:53:57] cdc at ccicon dot com

I assume you meant ze1_compatiblity_mode and compact was just a typo? 
Yes compatibility_mode is set.  It is explicitly set numerous places
within the Sugar Code.  I can try changing it, but I'm assuming it was
set within the code for a reason.

I'll try changing it and see what happens.



[2005-10-27 17:27:49] [EMAIL PROTECTED]

When getting the error is ze1 compact mode enabled or disabled and does
changing the setting alter the behaviour in any way?



[2005-10-27 11:56:02] [EMAIL PROTECTED]

I can't say the exact point of failure (though its due to how the
objects are linked to each other), but I recently had to get a highly
modified version of this running under 5.1 and it was falling into
infinite loops. Had to disable the ze1.compatibility_mode, remove the
majority of explicit reference usage (xxx =  object) and use some
explcit clone calls in spots. Runs stable after those changes, so not
sure if this is just a PHP compatbility issue.



[2005-10-26 21:00:22] cdc at ccicon dot com

From the application logs, it is apparent that many hundreds, even
thousands of lines of code are executing successfully after the post
before this out of memory condition occurs.  I have not yet been able
to trace the exact code location as I cannot step the code in my Zend
Studios environment using php 5.1.  It appears the the code may be
dying on either and array_merge or in a mysql call.  I will roll back
to php 5.0.5, which I can step in the Zend debugger, and attempt to
isolate the exact section of code which is generating these errors.  If
I can locate it, I can perhaps write a small test script to reproduce
the error under the CVS snapshot release.

This will likely take me a day or two to complete.

Thanks for your continued attention to this problem.

TTYL
  CDC



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

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


#34920 [Opn-Asn]: pg_update() fails

2005-11-01 Thread sniper
 ID:   34920
 Updated by:   [EMAIL PROTECTED]
 Reported By:  n dot j dot saunders at gmail dot com
-Status:   Open
+Status:   Assigned
 Bug Type: PostgreSQL related
 Operating System: *
 PHP Version:  5CVS-2005-10-31 (cvs)
-Assigned To:  
+Assigned To:  helly
 New Comment:

Assigned to the maintainer (according to EXTENSIONS file :)


Previous Comments:


[2005-10-24 10:31:47] chriskl at familyhealth dot com dot au

As a pgsql developer, this is definitel a bug.  These are the possible
fixes:

* Get rid of unknown and make the error message say 'this type is not
supported'

* Query for the domain's base type and use that.  AFAIK, from
postgresql 8.0 onwards the type of domain columns is always reported as
the base type via libPQ.  Might want to check when that changed.  (Might
be wrong tho.)

Check the PQftype function here:
http://www.postgresql.org/docs/8.0/interactive/libpq-exec.html#LIBPQ-EXEC-SELECT-INFO



[2005-10-20 00:10:46] n dot j dot saunders at gmail dot com

Tried as requested - Still unable to perform update, but at least we
now get an error:

Notice: pg_convert() [function.pg-convert]: Unknown or system data type
'area_code' for 'telephone_area' in c:\documents and
settings\neil.saunders\workspace\tvc\www\testpg.php on line 7

Notice: pg_update() [function.pg-update]: Unknown or system data type
'area_code' for 'telephone_area' in c:\documents and
settings\neil.saunders\workspace\tvc\www\testpg.php on line 10
ERROR

$db_conn = pg_connect(host=localhost port=5432 dbname=TVC
user=postgres password=xxx);

$data = array('telephone_area'='701');

pg_convert($db_conn, advertisers, $data);


$res = pg_update($db_conn, advertisers, $data, array('id'='2'));

if($res)
{
echo OK;
}
else
{
echo ERROR;
}

Is there any way that pg_convert/pg_update can perform this? Postgres
seems to handle the implied type conversion when the operation is
performed via SQL? Maybe just a documented caveat required?

Thanks Guys.



[2005-10-19 21:56:19] [EMAIL PROTECTED]

Please try using this CVS snapshot:

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

If you still able to reproduce it - please provide a short but complete
reproduce code and take a look into the Apache logs (if there are any
entries related to the problem - paste some of them here).



[2005-10-19 21:44:35] n dot j dot saunders at gmail dot com

Description:

pg_update seems to fail when updating an columns of a user defined
domain.

I have inherited table (advertisers) that contains, among others, the
columns telephone_country (integer), telephone_area (area domain),
telephone_number (number domain).

pg_update succeeds when VARCHAR fields are updated, but seems to fail
without error when fields of user defined domains are updated from the
array 

Reproduce code:
---
1. Define a Domain in an existing postgres database

e.g: area_code, domain with check

CREATE DOMAIN public.area_code AS
  varchar(10) NULL;

ALTER DOMAIN public.area_code
  ADD CONSTRAINT ck_area_code CHECK ((VALUE)::text ~
'^\\(?[0-9]\\)?[0-9]*$'::text);

2. Define a table in a postgres database that includes a column of the
type you just created.

CREATE TABLE public.users (
  username VARCHAR(20) NOT NULL, 
  altphone_area public.area_code);

3. Create a record in the table

INSERT INTO users (username, altphone_area) VALUES ('Neil',222);

3. Try and use pg_update to update this record

pg_update($db, users, array('altphone_area'=444),
array('username'='Neil'));

Expected result:

The record you created is updated, setting the value of
altphone_area=444

Actual result:
--
Nothing. No updates, no error messages.





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


#34832 [Opn-Fbk]: sprintf not reentrant

2005-11-01 Thread sniper
 ID:   34832
 Updated by:   [EMAIL PROTECTED]
 Reported By:  dolecek at stringdata dot cz
-Status:   Open
+Status:   Feedback
 Bug Type: Strings related
 Operating System: Windows 2000
 PHP Version:  5CVS-2005-10-17 (snap)
 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 to avoid embedding huge scripts into the report.




Previous Comments:


[2005-10-17 09:56:24] dolecek at stringdata dot cz

Tested with php5.1-win32-200510170630 and php5.0-win32-200510170030.

PHP 5.1 crashes Apache after several seconds of running the test. PHP
5.0.6-dev doesn't crash, but still exhibits the problem. Thus, the
problem is not fixed in snapshot.



[2005-10-12 12:07:00] dolecek at stringdata dot cz

Reproduce steps:
1. download FPDF 1.53 (fpdf153.zip), extract to suitable directory
accessible via web server
2. edit fpdf.php and replace line:

$this-_out('/CreationDate '.$this-_textstring('D:'.date('YmdHis')));

with:

$this-_out('/CreationDate '.$this-_textstring('D:20051011143910'));

This is necessary so that generated PDF don't differ gratuitously.

2. put attached script to the same directory as the modified fpdf.php

3. run:
  siege -c 10 -v -u http://server/path/to/script.php

The script:

$pdf=new FPDF();
$pdf-AddPage();

$pdf-SetFont('Arial','B',16);
$pdf-Cell(40,10,'Hello World!');
$pdf-SetFont('Arial','',10);
$pdf-Cell(60,10,'Powered by FPDF.',0,1,'C');

$content = $pdf-Output(false, 'S');

if (md5($content) != '38ec5b17d2cda871e21b28ecaeecd08d') {
   trigger_error('pdf generation test bug', E_USER_ERROR);
}



[2005-10-11 17:31:41] dolecek at stringdata dot cz

Description:

I'm using PHP with Apache 1.3.23 via apache module, using windows PHP
binaries downloaded from php.net.

If several parallelly running scripts execute same blocks of code using
sprintf(%.2f, $somefloat*$otherfloat), occassionally incorrect float
number is printed or even one character of the float contains binary
NUL.

Easy way to trigger this is to have a FPDF script generating a PDF
document, and have something which calls this script via web request in
parallel, so that all scripts are executed within the context of single
web server process. The problem appears in about 1% of generated
documents. The problem is repeatably in my environment, I can try to
put together simplier version of reproducing script if need be.

If I replace the above contruct with
number_format($somefloat*$otherfloat, 2, '.', ''), it works without
problem and no problem occurs.

The length of the gardbled output always exactly matches the length of
non-gardbled output, FWIW.

This suggests there is some kind of reentrancy problem with the
sprintf() routine, at least when printing floats. Perhaps some stack
alignment issue or something equally esoteric?

The problem exists in 5.1b3, 5.1.0rc1, 5.0.5. I did not check other
versions.

The type of bug has been set to repoducible crash due to missing
'Memory corruption' category and since this _might_ cause a crash (tho
no crash has been observed) - feel free to change to anything more
appropriate if need be.

Bug #21659 might actually be same problem, tho #21659 has been shrugged
off as miscompilation problem.







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


#35044 [Opn-Fbk]: Segmentation fault

2005-11-01 Thread johannes
 ID:   35044
 Updated by:   [EMAIL PROTECTED]
 Reported By:  boris at psyonline dot ru
-Status:   Open
+Status:   Feedback
 Bug Type: Reproducible crash
 Operating System: Linux 2.6.14-rc2
 PHP Version:  5.0.5
 New Comment:

Please try using this CVS snapshot:

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

Couldn't reproduce with current CVS version. 


Previous Comments:


[2005-11-01 10:59:06] boris at psyonline dot ru

Description:

Server not found. Segmentation fault

Reproduce code:
---
?php
function any_func () { 
   return any_func;
} 

$any_var = any_value;
switch ($any_var) { 
   default:
  class any_class {  
 function any_class_func() {  
   echo any_class_func .any_func().;
 } 
  } 
  
  $any_class = new any_class();
  $any_class-any_class_func(); 
} 
?

Expected result:

any_class_func any_func

Actual result:
--
Server not found. Segmentation fault





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


#34904 [Opn-Bgs]: Relocation error in libphp5.so when starting Apache2

2005-11-01 Thread sniper
 ID:   34904
 Updated by:   [EMAIL PROTECTED]
 Reported By:  sean dot healey at bayernlb dot co dot uk
-Status:   Open
+Status:   Bogus
 Bug Type: Sybase-ct (ctlib) related
 Operating System: Solaris 8
 PHP Version:  5.0.5
 New Comment:

This still isn't PHP bug.



Previous Comments:


[2005-10-27 18:46:49] sean dot healey at bayernlb dot co dot uk

Just another thing to note: The following message appears during 'make
install' ...

libtool: install: warning: remember to run `libtool --finish
/var/build/php-5.0.5/libs'

I would expect to see the message ...

--
Libraries have been installed in:
   /var/build/php-5.0.5/libs

If you ever happen to want to link against installed libraries
in a given directory, LIBDIR, you must either use libtool, and
specify the full pathname of the library, or use the `-LLIBDIR'
flag during linking and do at least one of the following:
   - add LIBDIR to the `LD_LIBRARY_PATH' environment variable
 during execution
   - use the `-RLIBDIR' linker flag

See any operating system documentation about shared libraries for
more information, such as the ld(1) and ld.so(8) manual pages.
--

... during the install phase, but this is missing. I presume this is
purely informational?

Sorry - I know this is unrelated to the above, just thought I should
bring it to your attention.



[2005-10-27 18:18:23] sean dot healey at bayernlb dot co dot uk

I have managed to get around the build problem by sym-linking
libintl.so - libintl.so.1 in the Sybase libraries path. Apache2 now
starts with the php5 module configured.

This seems to me to be an issue with the PHP build - we have no such
problems compiling other CTLIB applications!

Please note - the 'duplicate' name of the libintl library is NOT
Sybase's problem. Sybase support say that they created that library
'years' before Solaris introduced one of the same name.

Bittersweet victory though, because now sybase_connect() won't connect
despite the interfaces file being present, correct and configured in
php.ini.



[2005-10-27 11:30:54] sean dot healey at bayernlb dot co dot uk

Whoah! Please don't be misled by the configure script I submitted in
this bug report - the LDFLAGS and CPPFLAGS variables were set during my
attempts to work around the problem because I originally thought that
the build was picking up the wrong libtcl.so. I have since verified
that the only copies of this library on my system are under the Sybase
paths.

It does appear that the wrong libintl.so library is being picked up -
it should be using the one under the Sybase path, but is ignoring it
and using the one under /usr/lib instead.

I have tried this build against both the Sybase 12.0 and 12.5 client
libraries with identical results.

My original configure script is:

#!/usr/bin/sh

DSQUERY=fx_dbserver2_ds
SYBASE=/dpkg/sybase/sybase12_5
SYBASE_OCS=OCS-12_5
LD_LIBRARY_PATH=$SYBASE/$SYBASE_OCS/lib:/usr/local/lib:$LD_LIBRARY_PATH
PATH=/usr/ccs/bin:$PATH

export DSQUERY SYBASE SYBASE_OCS LD_LIBRARY_PATH PATH

cd php-5.0.5

./configure \
  --prefix=/usr/local/php \
  --with-apxs2=/usr/local/apache2/bin/apxs \
  --with-sybase-ct=$SYBASE/$SYBASE_OCS \
  --without-bz2

This produces a libphp5.so which is linked as follows:

ldd /usr/local/apache2/modules/libphp5.so
libtcl.so =
/dpkg/sybase/sybase12_5/OCS-12_5/lib/libtcl.so
libintl.so.1 =  /usr/lib/libintl.so.1
libcomn.so =   
/dpkg/sybase/sybase12_5/OCS-12_5/lib/libcomn.so
libct.so =  /dpkg/sybase/sybase12_5/OCS-12_5/lib/libct.so
libcs.so =  /dpkg/sybase/sybase12_5/OCS-12_5/lib/libcs.so
libresolv.so.2 =/usr/lib/libresolv.so.2
libm.so.1 = /usr/lib/libm.so.1
libdl.so.1 =/usr/lib/libdl.so.1
libnsl.so.1 =   /usr/lib/libnsl.so.1
libsocket.so.1 =/usr/lib/libsocket.so.1
libz.so.1 = /usr/lib/libz.so.1
libxml2.so.2 =  /usr/local/lib/libxml2.so.2
libiconv.so.2 = /usr/local/lib/libiconv.so.2
libc.so.1 = /usr/lib/libc.so.1
libmp.so.2 =/usr/lib/libmp.so.2
libpthread.so.1 =   /usr/lib/libpthread.so.1
libgcc_s.so.1 = /usr/local/lib/libgcc_s.so.1
/usr/platform/SUNW,Ultra-80/lib/libc_psr.so.1
libthread.so.1 =/usr/lib/libthread.so.1


NOTE that the reference to libintl is still linked to the wrong
library.

I have investigated further and found that libintl.so.1 doesn't exist
under the Sybase path - only libintl.so is found there. I need to
somehow force the build to pick up the Sybase library instead of the
Solaris 

#34834 [Opn-Bgs]: array_merge_recursive merges objects with arrays

2005-11-01 Thread sniper
 ID:   34834
 Updated by:   [EMAIL PROTECTED]
 Reported By:  tomas_matousek at hotmail dot com
-Status:   Open
+Status:   Bogus
 Bug Type: Arrays related
 Operating System: WinXP
 PHP Version:  5.1.0RC1
 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:


[2005-10-11 23:35:21] tomas_matousek at hotmail dot com

Description:

Although one cannot pass obejects to array_merge_recursive() function,
it looks like it doesn't ignore objects at all.
If objects are contained in the array it merges them as if they were
arrays of fields. I think it is not good to treat objects in this way
when other array functions doesn't do so (e.g. array_walk_recursive
doesn't step to fields of objects).

Reproduce code:
---
class A 
{ 
  var $field = array(1);
}

$a = new A;
$x = array(a = $a);

$y = array(a = array(field = array(2)));

var_dump(array_merge_recursive($x,$y));

Expected result:

array(1) {
  [a]=
  array(2) {
[0]=
object(A)#1 (1) {
  [field]=
  array(1) {
[0]=
int(1)
  }
}
[field]=
array(1) {
  [0]=
  int(2)
}
  }
}


Actual result:
--
array(1) {
  [a]=
  array(1) {
[field]=
array(2) {
  [0]=
  int(1)
  [1]=
  int(2)
}
  }
}






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


#34794 [Opn-Asn]: proc_close() hangs when used with two processes

2005-11-01 Thread sniper
 ID:   34794
 Updated by:   [EMAIL PROTECTED]
 Reported By:  e-t172 at e-t172 dot net
-Status:   Open
+Status:   Assigned
 Bug Type: Program Execution
 Operating System: Linux
 PHP Version:  5CVS-2005-10-09 (snap)
-Assigned To:  
+Assigned To:  wez
 New Comment:

Assigned to the author of this stuff.


Previous Comments:


[2005-10-09 20:12:09] e-t172 at e-t172 dot net

Same problem with the last CVS Snapshot.



[2005-10-09 18:23:40] e-t172 at e-t172 dot net

Description:

(i am french, sorry for my bad english)

1. Open two processes with proc_open()
2. Try to close them : it works only if you close the second one first,
otherwise it hangs

Reproduce code:
---
?php
echo('Opening process 1'.\n);
$process1 = proc_open('cat', array(0 = array('pipe', 'r'), 1 =
array('pipe', 'r')), $pipes1);
echo('Opening process 2'.\n);
$process2 = proc_open('cat', array(0 = array('pipe', 'r'), 1 =
array('pipe', 'r')), $pipes2);

// WORKS :

//echo('Closing process 2'.\n);
//fclose($pipes2[0]); fclose($pipes2[1]); proc_close($process2);
//echo('Closing process 1'.\n);
//fclose($pipes1[0]); fclose($pipes1[1]); proc_close($process1);

// DOESN'T WORK :

echo('Closing process 1'.\n);
fclose($pipes1[0]); fclose($pipes1[1]); proc_close($process1);
echo('Closing process 2'.\n);
fclose($pipes2[0]); fclose($pipes2[1]); proc_close($process2);
?

Expected result:

$ php -f test.php
Opening process 1
Opening process 2
Closing process 1
Closing process 2
$ 

Actual result:
--
$ php -f test.php
Opening process 1
Opening process 2
Closing process 1

(HANGS)





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


#34779 [Opn-Bgs]: Default value of output_buffering (4096) causes memory overflow on Windows XP

2005-11-01 Thread sniper
 ID:   34779
 Updated by:   [EMAIL PROTECTED]
 Reported By:  jan dot lachman at stringdata dot cz
-Status:   Open
+Status:   Bogus
 Bug Type: Output Control
 Operating System: WindowsXP
 PHP Version:  5CVS-2005-10-07
 New Comment:

This is impossible. If you set output_buffering to 'On' it's exactly
same as setting it to 4096. So you're really doing something else or
not telling us everything.



Previous Comments:


[2005-10-24 09:34:26] jan dot lachman at stringdata dot cz

Ok. I use standard ab.exe(Win) or OpenSTA(Win) or Siege(from linux),
etc on client side. On server side I have small script (like
index.php) that includes:
?
phpinfo();
sleep 5;
?
nothing else. How it works you know. I know that if my php use
output_buffering = 4096 - our server goes down, but when I use
output_buffering = On, it works perfectly!



[2005-10-24 00:28:55] [EMAIL PROTECTED]

I have just tried 1 connections to phpinfo() page an memory usage
has stablized at around 21 MB for 10 concurrent connections.

Please post a complite test script that would allow us to trace the
problem.



[2005-10-07 16:57:08] jan dot lachman at stringdata dot cz

Nothing. I mean without change. With default value (output_buffering =
4096) bad, with output_buffering = On working perfectly. On request I
may send screenshot of Task Manager (with-and-without directive).
Thanks.



[2005-10-07 15:39:08] [EMAIL PROTECTED]

Please try using this CVS snapshot:

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





[2005-10-07 14:53:26] jan dot lachman at stringdata dot cz

Description:

On MS Windows XP Pro (SP2) and Apache 2.0.5.4 has PHP(php5apache2.dll
module) a serious problem with value output_buffering = 4096. When I
start the web-server, then  I run benchmarking programs (like siege or
ab.exe or OpenSTA) and I try to access a small script that includes
phpinfo (with 50-100 simulated user connections), I get memory load
about 10MB within !one! minute (and growing) - until the RAM (715MB) is
available.  Then total crash follows after this.

After two-days testing, we found (with my team-mate) little way to
solve this problem. If we set output_buffering = On , it's working
perfectly.






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


#31594 [Opn-Fbk]: virtual(): Unable to include 'xxx' - error finding URI

2005-11-01 Thread sniper
 ID:   31594
 Updated by:   [EMAIL PROTECTED]
 Reported By:  per at computer dot org
-Status:   Open
+Status:   Feedback
 Bug Type: Apache2 related
 Operating System: linux 2.4.26
 PHP Version:  5.*, 4.*
 New Comment:

Please use the EXACT same url's as asked to. You were asked to try the
latest, not 'stable'.




Previous Comments:


[2005-10-22 13:10:28] per at computer dot org

I should add - I am now getting a line with no acceptable variant:
for part1 in my apache2 error-log.



[2005-10-22 13:05:20] per at computer dot org

Ran my testcase using php5-STABLE-200510220840 - it still fails:

part0+
Warning: virtual() [function.virtual]: Unable to include 'part1' -
error finding URI in
/srv/www/vhosts/www/htdocs/phpbug-31594/part0.phtml on line 11



[2005-10-19 17:24:00] [EMAIL PROTECTED]

Please try using this CVS snapshot:

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





[2005-09-14 08:38:04] per at computer dot org

Actually no - apache content negotiation takes care of that.  Also, as
discussed earlier, the example works fine in php 4.3.8.



[2005-09-13 15:48:44] shamaniacwizardfromoz at yahoo dot de

The file called should exist.
You call 'part1' using virtual() but named the file 'part1.phtml'.
My comment is hopefully not just completely stupid.



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

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


#35032 [Fbk-Opn]: pdo_dblib can't find the FreeTDS includes on some systems

2005-11-01 Thread [EMAIL PROTECTED]
 ID:   35032
 User updated by:  [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Feedback
+Status:   Open
 Bug Type: PDO related
 Operating System: Mac OS X
 PHP Version:  5CVS-2005-10-28 (CVS)
 Assigned To:  Wez
 New Comment:

Yeah, I was afraid this would happen. The patch can be downloaded at
http://eloris.spheroid.info/~henkka/tmp/pdo_dblib-config.m4.patch


Previous Comments:


[2005-11-01 02:43:28] [EMAIL PROTECTED]

Provide a link to a downloadable patch against PHP_5_1 branch; your
patch would not apply.



[2005-10-31 11:15:08] [EMAIL PROTECTED]

Description:

On some systems FreeTDS include files are being installed on
$prefix/include/freetds instead of $prefix/include where configure is
trying to find them.

I have modified the ext/pdo_dblib/config.m4 to also search that
directory with the following patch:

--- config.m4   2005-10-31 10:08:18.0 +0200
+++ config.m4.new   2005-10-31 10:17:30.0 +0200
@@ -10,13 +10,17 @@
 
 if test $PHP_PDO_DBLIB != no; then
 
-  PDO_FREETDS_INSTALLATION_DIR=
   if test $PHP_PDO_DBLIB = yes; then
 
 for i in /usr/local /usr; do
   if test -f $i/include/tds.h; then
 PDO_FREETDS_INSTALLATION_DIR=$i
+PDO_FREETDS_INCLUDE_DIR=$i/include
 break
+  elif test -f $i/include/freetds/tds.h; then
+PDO_FREETDS_INSTALLATION_DIR=$i
+PDO_FREETDS_INCLUDE_DIR=$i/include/freetds
+break;
   fi
 done
 
@@ -28,6 +32,10 @@
 
 if test -f $PHP_PDO_DBLIB/include/tds.h; then
   PDO_FREETDS_INSTALLATION_DIR=$PHP_PDO_DBLIB
+  PDO_FREETDS_INCLUDE_DIR=$PHP_PDO_DBLIB/include
+elif test -f $PHP_PDO_DBLIB/include/freetds/tds.h; then
+  PDO_FREETDS_INSTALLATION_DIR=$PHP_PDO_DBLIB
+  PDO_FREETDS_INCLUDE_DIR=$PHP_PDO_DBLIB/include/freetds
 else
   AC_MSG_ERROR(Directory $PHP_PDO_DBLIB is not a FreeTDS
installation directory)
 fi
@@ -41,11 +49,9 @@
  AC_MSG_ERROR(Could not find
$PDO_FREETDS_INSTALLATION_DIR/$PHP_LIBDIR/libtds.[a|so])
   fi
 
-  PDO_DBLIB_INCDIR=$PDO_FREETDS_INSTALLATION_DIR/include
-  PDO_DBLIB_LIBDIR=$PDO_FREETDS_INSTALLATION_DIR/$PHP_LIBDIR
+  PHP_ADD_INCLUDE($PDO_FREETDS_INCLUDE_DIR)
+  PHP_ADD_LIBRARY_WITH_PATH(sybdb,
$PDO_FREETDS_INSTALLATION_DIR/$PHP_LIBDIR, PDO_DBLIB_SHARED_LIBADD)
 
-  PHP_ADD_INCLUDE($PDO_DBLIB_INCDIR)
-  PHP_ADD_LIBRARY_WITH_PATH(sybdb, $PDO_DBLIB_LIBDIR,
PDO_DBLIB_SHARED_LIBADD)
   ifdef([PHP_CHECK_PDO_INCLUDES],
   [
 PHP_CHECK_PDO_INCLUDES







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


#35046 [NEW]: bad css when using phpinfo()

2005-11-01 Thread spam at gemal dot dk
From: spam at gemal dot dk
Operating system: Linux
PHP version:  5.0.5
PHP Bug Type: PHP options/info functions
Bug description:  bad css when using phpinfo()

Description:

Error: Selector expected.  Ruleset ignored due to bad selector.
Source file: phpinfo.php
Line: 23

Error: Unexpected end of file while searching for closing } of invalid
rule set.
Source file: phpinfo.php
Line: 23


Reproduce code:
---
?php
phpinfo();
? 

Expected result:

style type=text/css!--
blabla
//--/style

should be:
style type=text/css
blabla
/style

to be valid css



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


#35047 [NEW]: fgetcsv cannot handle foreigh characters

2005-11-01 Thread wanthalf at centrum dot cz
From: wanthalf at centrum dot cz
Operating system: Linux
PHP version:  5.0.5
PHP Bug Type: Filesystem function related
Bug description:  fgetcsv cannot handle foreigh characters

Description:

This is exactly the same problem as bug 10896 or 30335. I haven't realized
the problem with any PHP4 version, but I have realized it with every PHP5
version I've tried.

Reproduce code:
---
See bug 10896.


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


#35047 [Opn-Bgs]: fgetcsv cannot handle foreigh characters

2005-11-01 Thread derick
 ID:   35047
 Updated by:   [EMAIL PROTECTED]
 Reported By:  wanthalf at centrum dot cz
-Status:   Open
+Status:   Bogus
 Bug Type: Filesystem function related
 Operating System: Linux
 PHP Version:  5.0.5
 New Comment:

This is not a bug, you need to set the correct locale with setlocale()
for this function to work with special characters.


Previous Comments:


[2005-11-01 13:16:20] wanthalf at centrum dot cz

Description:

This is exactly the same problem as bug 10896 or 30335. I haven't
realized the problem with any PHP4 version, but I have realized it with
every PHP5 version I've tried.

Reproduce code:
---
See bug 10896.






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


#35047 [Bgs]: fgetcsv cannot handle foreigh characters

2005-11-01 Thread wanthalf at centrum dot cz
 ID:   35047
 User updated by:  wanthalf at centrum dot cz
 Reported By:  wanthalf at centrum dot cz
 Status:   Bogus
 Bug Type: Filesystem function related
 Operating System: Linux
 PHP Version:  5.0.5
 New Comment:

Oh. Does it mean it won't work anymore if there is no 
UTF-8-ish locale precompiled on any foreign webhosting 
server? 
BTW: What about Windows??


Previous Comments:


[2005-11-01 13:19:31] [EMAIL PROTECTED]

This is not a bug, you need to set the correct locale with setlocale()
for this function to work with special characters.



[2005-11-01 13:16:20] wanthalf at centrum dot cz

Description:

This is exactly the same problem as bug 10896 or 30335. I haven't
realized the problem with any PHP4 version, but I have realized it with
every PHP5 version I've tried.

Reproduce code:
---
See bug 10896.






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


#35032 [Opn-Asn]: pdo_dblib can't find the FreeTDS includes on some systems

2005-11-01 Thread sniper
 ID:   35032
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Open
+Status:   Assigned
 Bug Type: PDO related
 Operating System: Mac OS X
 PHP Version:  5CVS-2005-10-28 (CVS)
-Assigned To:  Wez
+Assigned To:  wez


Previous Comments:


[2005-11-01 13:00:19] [EMAIL PROTECTED]

Yeah, I was afraid this would happen. The patch can be downloaded at
http://eloris.spheroid.info/~henkka/tmp/pdo_dblib-config.m4.patch



[2005-11-01 02:43:28] [EMAIL PROTECTED]

Provide a link to a downloadable patch against PHP_5_1 branch; your
patch would not apply.



[2005-10-31 11:15:08] [EMAIL PROTECTED]

Description:

On some systems FreeTDS include files are being installed on
$prefix/include/freetds instead of $prefix/include where configure is
trying to find them.

I have modified the ext/pdo_dblib/config.m4 to also search that
directory with the following patch:

--- config.m4   2005-10-31 10:08:18.0 +0200
+++ config.m4.new   2005-10-31 10:17:30.0 +0200
@@ -10,13 +10,17 @@
 
 if test $PHP_PDO_DBLIB != no; then
 
-  PDO_FREETDS_INSTALLATION_DIR=
   if test $PHP_PDO_DBLIB = yes; then
 
 for i in /usr/local /usr; do
   if test -f $i/include/tds.h; then
 PDO_FREETDS_INSTALLATION_DIR=$i
+PDO_FREETDS_INCLUDE_DIR=$i/include
 break
+  elif test -f $i/include/freetds/tds.h; then
+PDO_FREETDS_INSTALLATION_DIR=$i
+PDO_FREETDS_INCLUDE_DIR=$i/include/freetds
+break;
   fi
 done
 
@@ -28,6 +32,10 @@
 
 if test -f $PHP_PDO_DBLIB/include/tds.h; then
   PDO_FREETDS_INSTALLATION_DIR=$PHP_PDO_DBLIB
+  PDO_FREETDS_INCLUDE_DIR=$PHP_PDO_DBLIB/include
+elif test -f $PHP_PDO_DBLIB/include/freetds/tds.h; then
+  PDO_FREETDS_INSTALLATION_DIR=$PHP_PDO_DBLIB
+  PDO_FREETDS_INCLUDE_DIR=$PHP_PDO_DBLIB/include/freetds
 else
   AC_MSG_ERROR(Directory $PHP_PDO_DBLIB is not a FreeTDS
installation directory)
 fi
@@ -41,11 +49,9 @@
  AC_MSG_ERROR(Could not find
$PDO_FREETDS_INSTALLATION_DIR/$PHP_LIBDIR/libtds.[a|so])
   fi
 
-  PDO_DBLIB_INCDIR=$PDO_FREETDS_INSTALLATION_DIR/include
-  PDO_DBLIB_LIBDIR=$PDO_FREETDS_INSTALLATION_DIR/$PHP_LIBDIR
+  PHP_ADD_INCLUDE($PDO_FREETDS_INCLUDE_DIR)
+  PHP_ADD_LIBRARY_WITH_PATH(sybdb,
$PDO_FREETDS_INSTALLATION_DIR/$PHP_LIBDIR, PDO_DBLIB_SHARED_LIBADD)
 
-  PHP_ADD_INCLUDE($PDO_DBLIB_INCDIR)
-  PHP_ADD_LIBRARY_WITH_PATH(sybdb, $PDO_DBLIB_LIBDIR,
PDO_DBLIB_SHARED_LIBADD)
   ifdef([PHP_CHECK_PDO_INCLUDES],
   [
 PHP_CHECK_PDO_INCLUDES







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


#34978 [Asn-Fbk]: php out of memory or segmentation fault while installing sugarcrm 3.5.1a

2005-11-01 Thread dmitry
 ID:   34978
 Updated by:   [EMAIL PROTECTED]
 Reported By:  cdc at ccicon dot com
-Status:   Assigned
+Status:   Feedback
 Bug Type: Scripting Engine problem
 Operating System: linux i386
 PHP Version:  5CVS-2005-10-31 (snap)
 Assigned To:  dmitry
 New Comment:

Can anybody provide a test case?
May be this bug already fixed in HEAD and PHP_5_1.


Previous Comments:


[2005-11-01 11:41:27] [EMAIL PROTECTED]

This is really critical issue. Obviously that stupid compatibility
mode misbehaves still?



[2005-10-27 19:10:23] cdc at ccicon dot com

The zend.ze_compatiblity_mode is set to 1 in the index.php file and
several other files using the following test for php version number

if (substr(phpversion(), 0, 1) == 5) {
ini_set(zend.ze1_compatibility_mode, 1);
}

Disabling this option (ie zend.ze_compatiblity_mode=0) under php 5.0.5
and under the last cvs snapshot that was recommended seems to solve
this race condition.  I have not tested the code fully to see that this
hasn't introduced other problems.  However, it does remove the out of
memory and segfault problems.

Were there changes made in php 5.0.5 and later that make this option
obsolete.  Or, will disabling this condition lead to other compatility
issues?

TTYL
  CDC



[2005-10-27 18:53:57] cdc at ccicon dot com

I assume you meant ze1_compatiblity_mode and compact was just a typo? 
Yes compatibility_mode is set.  It is explicitly set numerous places
within the Sugar Code.  I can try changing it, but I'm assuming it was
set within the code for a reason.

I'll try changing it and see what happens.



[2005-10-27 17:27:49] [EMAIL PROTECTED]

When getting the error is ze1 compact mode enabled or disabled and does
changing the setting alter the behaviour in any way?



[2005-10-27 11:56:02] [EMAIL PROTECTED]

I can't say the exact point of failure (though its due to how the
objects are linked to each other), but I recently had to get a highly
modified version of this running under 5.1 and it was falling into
infinite loops. Had to disable the ze1.compatibility_mode, remove the
majority of explicit reference usage (xxx =  object) and use some
explcit clone calls in spots. Runs stable after those changes, so not
sure if this is just a PHP compatbility issue.



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

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


#34978 [Fbk-Opn]: php out of memory or segmentation fault while installing sugarcrm 3.5.1a

2005-11-01 Thread cdc at ccicon dot com
 ID:   34978
 User updated by:  cdc at ccicon dot com
 Reported By:  cdc at ccicon dot com
-Status:   Feedback
+Status:   Open
 Bug Type: Scripting Engine problem
 Operating System: linux i386
-PHP Version:  5CVS-2005-10-31 (snap)
+PHP Version:  5.0.5
 Assigned To:  dmitry
 New Comment:

I have tried to locate the exact code triggering the bug but have so
far been unsuccessfull.  So, I have been unable to come up with a
simple test case.  The bug is easily reproducible by trying to load and
run the Sugar code available here 
http://www.sugarforge.org/frs/download.php/466/SugarSuite-3.5.1a.zip

I can tell you that the bug still existed in the following CVS
snapshot.

php5-200510251830

If you believe that it might have been fixed in a newer snapshot, I
would be happy to test it.  Just point me at it.

TTYL
  CDC


Previous Comments:


[2005-11-01 13:40:27] [EMAIL PROTECTED]

Can anybody provide a test case?
May be this bug already fixed in HEAD and PHP_5_1.



[2005-11-01 11:41:27] [EMAIL PROTECTED]

This is really critical issue. Obviously that stupid compatibility
mode misbehaves still?



[2005-10-27 19:10:23] cdc at ccicon dot com

The zend.ze_compatiblity_mode is set to 1 in the index.php file and
several other files using the following test for php version number

if (substr(phpversion(), 0, 1) == 5) {
ini_set(zend.ze1_compatibility_mode, 1);
}

Disabling this option (ie zend.ze_compatiblity_mode=0) under php 5.0.5
and under the last cvs snapshot that was recommended seems to solve
this race condition.  I have not tested the code fully to see that this
hasn't introduced other problems.  However, it does remove the out of
memory and segfault problems.

Were there changes made in php 5.0.5 and later that make this option
obsolete.  Or, will disabling this condition lead to other compatility
issues?

TTYL
  CDC



[2005-10-27 18:53:57] cdc at ccicon dot com

I assume you meant ze1_compatiblity_mode and compact was just a typo? 
Yes compatibility_mode is set.  It is explicitly set numerous places
within the Sugar Code.  I can try changing it, but I'm assuming it was
set within the code for a reason.

I'll try changing it and see what happens.



[2005-10-27 17:27:49] [EMAIL PROTECTED]

When getting the error is ze1 compact mode enabled or disabled and does
changing the setting alter the behaviour in any way?



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

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


#35048 [Opn-Fbk]: parse_ini_file will be influenced by putenv in special situation

2005-11-01 Thread sniper
 ID:   35048
 Updated by:   [EMAIL PROTECTED]
 Reported By:  liber at iproom dot com
-Status:   Open
+Status:   Feedback
 Bug Type: *General Issues
 Operating System: Windows XP
 PHP Version:  5.0.5
 New Comment:

Please try using this CVS snapshot:

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




Previous Comments:


[2005-11-01 13:39:37] liber at iproom dot com

Description:

First, var_dump the result read by parse_ini_file is:
array (
  'dbHost' = 'localhost',
  'dbUser' = 'mmcwebapp',
  'dbPassword' = '',
  'dbName' = 'faraday',
)

but i don't know why, everytime after
the command: putenv(TZ=);

the result will change as follow:

array (
  'dbHost' = 'localhost',
  'dbUser' = 'mmcwebapp',
  'dbPassword' = '',
  'faradayc8XC9-2' = 'faraday',
)

I can't not figure out where problem is,
then I use Zend Studio and add a watch like this

var_export(parse_ini_file(DBX_CONFIG_FILE),1)

the DBX_CONFIG_FILE is defined as like as c:\a.ini

then I saw the changing in debug mode(step by step).






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


#35032 [Asn-Csd]: pdo_dblib can't find the FreeTDS includes on some systems

2005-11-01 Thread iliaa
 ID:   35032
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Assigned
+Status:   Closed
 Bug Type: PDO related
 Operating System: Mac OS X
 PHP Version:  5CVS-2005-10-28 (CVS)
 Assigned To:  wez
 New Comment:

This bug has been fixed in CVS.

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




Previous Comments:


[2005-11-01 13:00:19] [EMAIL PROTECTED]

Yeah, I was afraid this would happen. The patch can be downloaded at
http://eloris.spheroid.info/~henkka/tmp/pdo_dblib-config.m4.patch



[2005-11-01 02:43:28] [EMAIL PROTECTED]

Provide a link to a downloadable patch against PHP_5_1 branch; your
patch would not apply.



[2005-10-31 11:15:08] [EMAIL PROTECTED]

Description:

On some systems FreeTDS include files are being installed on
$prefix/include/freetds instead of $prefix/include where configure is
trying to find them.

I have modified the ext/pdo_dblib/config.m4 to also search that
directory with the following patch:

--- config.m4   2005-10-31 10:08:18.0 +0200
+++ config.m4.new   2005-10-31 10:17:30.0 +0200
@@ -10,13 +10,17 @@
 
 if test $PHP_PDO_DBLIB != no; then
 
-  PDO_FREETDS_INSTALLATION_DIR=
   if test $PHP_PDO_DBLIB = yes; then
 
 for i in /usr/local /usr; do
   if test -f $i/include/tds.h; then
 PDO_FREETDS_INSTALLATION_DIR=$i
+PDO_FREETDS_INCLUDE_DIR=$i/include
 break
+  elif test -f $i/include/freetds/tds.h; then
+PDO_FREETDS_INSTALLATION_DIR=$i
+PDO_FREETDS_INCLUDE_DIR=$i/include/freetds
+break;
   fi
 done
 
@@ -28,6 +32,10 @@
 
 if test -f $PHP_PDO_DBLIB/include/tds.h; then
   PDO_FREETDS_INSTALLATION_DIR=$PHP_PDO_DBLIB
+  PDO_FREETDS_INCLUDE_DIR=$PHP_PDO_DBLIB/include
+elif test -f $PHP_PDO_DBLIB/include/freetds/tds.h; then
+  PDO_FREETDS_INSTALLATION_DIR=$PHP_PDO_DBLIB
+  PDO_FREETDS_INCLUDE_DIR=$PHP_PDO_DBLIB/include/freetds
 else
   AC_MSG_ERROR(Directory $PHP_PDO_DBLIB is not a FreeTDS
installation directory)
 fi
@@ -41,11 +49,9 @@
  AC_MSG_ERROR(Could not find
$PDO_FREETDS_INSTALLATION_DIR/$PHP_LIBDIR/libtds.[a|so])
   fi
 
-  PDO_DBLIB_INCDIR=$PDO_FREETDS_INSTALLATION_DIR/include
-  PDO_DBLIB_LIBDIR=$PDO_FREETDS_INSTALLATION_DIR/$PHP_LIBDIR
+  PHP_ADD_INCLUDE($PDO_FREETDS_INCLUDE_DIR)
+  PHP_ADD_LIBRARY_WITH_PATH(sybdb,
$PDO_FREETDS_INSTALLATION_DIR/$PHP_LIBDIR, PDO_DBLIB_SHARED_LIBADD)
 
-  PHP_ADD_INCLUDE($PDO_DBLIB_INCDIR)
-  PHP_ADD_LIBRARY_WITH_PATH(sybdb, $PDO_DBLIB_LIBDIR,
PDO_DBLIB_SHARED_LIBADD)
   ifdef([PHP_CHECK_PDO_INCLUDES],
   [
 PHP_CHECK_PDO_INCLUDES







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


#35049 [NEW]: SOAP enhancement request

2005-11-01 Thread jefimm at hotmail dot com
From: jefimm at hotmail dot com
Operating system: ANY
PHP version:  5.0.5
PHP Bug Type: Feature/Change Request
Bug description:  SOAP enhancement request

Description:

Regarding the SOAP extension of the PHP 5.
Is there any way to access parsed soap header when using SoapServer
class?



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


#35050 [NEW]: PHP 5 do not recognize Capital I letters in function and class method names

2005-11-01 Thread satanistlav at mail dot ru
From: satanistlav at mail dot ru
Operating system: Linux
PHP version:  5.0.5
PHP Bug Type: Scripting Engine problem
Bug description:  PHP 5 do not recognize Capital I letters in function and 
class method names

Description:

The Linux hosting server I use recently upgraded PHP Version to 5.0.4.
After upgrade all function and and class methods those had capital I
letter in the function names became unrecognized by PHP. No such problem I
had in previouse version of PHP, and no problem in my local server (WinXP,
Apache 2, PHP v5.0.5)

Reproduce code:
---
//Part of mail class
.
/**
 * Sets Mailer to send message using SMTP.
 * @return void
 */
   function IsSMTP() {
   $this-Mailer = smtp;
   }

/**
 * Sets Mailer to send message using PHP mail() function.
 * @return void
 */
function IsMail() {
$this-Mailer = mail;
}
.
/*  I used class methods ***/
 .
 $mailer-IsHtml(true);
 $mailer-IsMail();
 .

Expected result:

Execution of class method is expected

Actual result:
--
/* I got error /
Fatal error: Call to undefined method PHPMailer::IsHtml() in  

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


#34834 [Bgs-Opn]: array_merge_recursive merges objects with arrays

2005-11-01 Thread tomas_matousek at hotmail dot com
 ID:   34834
 User updated by:  tomas_matousek at hotmail dot com
 Reported By:  tomas_matousek at hotmail dot com
-Status:   Bogus
+Status:   Open
 Bug Type: Arrays related
 Operating System: WinXP
 PHP Version:  5.1.0RC1
 New Comment:

Why this is not a bug? Can you explain why this function should treat
objects like arrays (and merges their fields with items of arrays which
is weird) while another array functions doesn't do so? It is not stated
in the documentation.


Previous Comments:


[2005-11-01 11:25:26] [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





[2005-10-11 23:35:21] tomas_matousek at hotmail dot com

Description:

Although one cannot pass obejects to array_merge_recursive() function,
it looks like it doesn't ignore objects at all.
If objects are contained in the array it merges them as if they were
arrays of fields. I think it is not good to treat objects in this way
when other array functions doesn't do so (e.g. array_walk_recursive
doesn't step to fields of objects).

Reproduce code:
---
class A 
{ 
  var $field = array(1);
}

$a = new A;
$x = array(a = $a);

$y = array(a = array(field = array(2)));

var_dump(array_merge_recursive($x,$y));

Expected result:

array(1) {
  [a]=
  array(2) {
[0]=
object(A)#1 (1) {
  [field]=
  array(1) {
[0]=
int(1)
  }
}
[field]=
array(1) {
  [0]=
  int(2)
}
  }
}


Actual result:
--
array(1) {
  [a]=
  array(1) {
[field]=
array(2) {
  [0]=
  int(1)
  [1]=
  int(2)
}
  }
}






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


#34729 [Asn]: SoapClient-SoapServer crashes under apache with 5.10RC2

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

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


Previous Comments:


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

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

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

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

It breaks quite consistently at this point. 

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

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

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



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

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



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

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

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

This is from a config line:
cscript /nologo configure.js 
--with-extra-includes=..\libiconv\include;..\libxml2\include;..\apache2\inclu
de
--with-extra-libs=..\libiconv\lib;..\libxml2\win32\lib;..\apache2\lib
--e
nable-sdo=shared --enable-soap=shared --enable-debug
--enable-apache2handler



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

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

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

The exact code I am using, cut 

#35049 [Opn-Bgs]: SOAP enhancement request

2005-11-01 Thread derick
 ID:   35049
 Updated by:   [EMAIL PROTECTED]
 Reported By:  jefimm at hotmail dot com
-Status:   Open
+Status:   Bogus
 Bug Type: Feature/Change Request
 Operating System: ANY
 PHP Version:  5.0.5
 New Comment:

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

Thank you for your interest in PHP.

This is not a support forum, if you have questions regarding the soap
extension ask them on the mailinglist.


Previous Comments:


[2005-11-01 14:43:37] jefimm at hotmail dot com

Description:

Regarding the SOAP extension of the PHP 5.
Is there any way to access parsed soap header when using SoapServer
class?







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


#35050 [Opn-Fbk]: PHP 5 do not recognize Capital I letters in function and class method names

2005-11-01 Thread derick
 ID:   35050
 Updated by:   [EMAIL PROTECTED]
 Reported By:  satanistlav at mail dot ru
-Status:   Open
+Status:   Feedback
 Bug Type: Scripting Engine problem
 Operating System: Linux
 PHP Version:  5.0.5
 New Comment:

What is your locale set to? Can you provide a link to phpinfo() output?


Previous Comments:


[2005-11-01 14:45:44] satanistlav at mail dot ru

Description:

The Linux hosting server I use recently upgraded PHP Version to 5.0.4.
After upgrade all function and and class methods those had capital I
letter in the function names became unrecognized by PHP. No such
problem I had in previouse version of PHP, and no problem in my local
server (WinXP, Apache 2, PHP v5.0.5)

Reproduce code:
---
//Part of mail class
.
/**
 * Sets Mailer to send message using SMTP.
 * @return void
 */
   function IsSMTP() {
   $this-Mailer = smtp;
   }

/**
 * Sets Mailer to send message using PHP mail() function.
 * @return void
 */
function IsMail() {
$this-Mailer = mail;
}
.
/*  I used class methods ***/
 .
 $mailer-IsHtml(true);
 $mailer-IsMail();
 .

Expected result:

Execution of class method is expected

Actual result:
--
/* I got error /
Fatal error: Call to undefined method PHPMailer::IsHtml() in  





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


#35051 [NEW]: Problem with empty()

2005-11-01 Thread storm at mail dot up dot com dot ua
From: storm at mail dot up dot com dot ua
Operating system: FreeBsd 5.3
PHP version:  5.0.5
PHP Bug Type: Scripting Engine problem
Bug description:  Problem with empty()

Description:

Various results empty() for nonexistent key 

Reproduce code:
---
$w=array('a'='','b'=array('dd'=1,'aa'=2));

foreach($w as $k=$v)
{
if(empty($v['dd']))
echo {$k}:emptybr\n;
else
echo {$k}:no emptybr\n;
}


Expected result:

a:emptybr  
b:no emptybr

(PHP 5.03 FreeBsd 4.9)

Actual result:
--
a:no emptybr  
b:no emptybr

(PHP 5.05 FreeBsd 5.3)

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


#34656 [NoF-Opn]: open_basedir restriction in effect although paths are set correctly

2005-11-01 Thread wolfram at schlich dot org
 ID:   34656
 User updated by:  wolfram at schlich dot org
 Reported By:  wolfram at schlich dot org
-Status:   No Feedback
+Status:   Open
 Bug Type: Safe Mode/open_basedir
 Operating System: Linux 2.2.16 i586
-PHP Version:  4.4.0
+PHP Version:  4.4.1
 New Comment:

Just tried with the freshly released 4.4.1, without luck:
--8--
Warning: fopen(): open_basedir restriction in effect.
File(/tmp/foo.bar) is not within the allowed path(s):
(/home/sites/site81/:/tmp/:/usr/share/pear/) in
/home/sites/site81/web/fopen.php on line 3

Warning: fopen(/tmp/foo.bar): failed to open stream: Operation not
permitted in /home/sites/site81/web/fopen.php on line 3
--8--

--8--[ access.conf ]--8--
DirectoryMatch /home/sites/site81/
php_admin_value open_basedir
/home/sites/site81/:/tmp/:/usr/share/pear/
/DirectoryMatch
--8--


Previous Comments:


[2005-10-05 01:00:09] php-bugs at lists dot php dot net

No feedback was provided for this bug for over a week, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to Open.



[2005-09-27 19:53:27] [EMAIL PROTECTED]

Give feedback when you have some..



[2005-09-27 19:47:49] wolfram at schlich dot org

thanks! will do.



[2005-09-27 19:27:01] [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

Something related to open_basedir and the paths was just fixed. Give it
an hour or two.




[2005-09-27 19:24:09] wolfram at schlich dot org

sorry, I cannot use anything other than php4 on that machines.
they are used for webhosting, the customers depend on php4.
thanks.



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

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


#35050 [Fbk-Opn]: PHP 5 do not recognize Capital I letters in function and class method names

2005-11-01 Thread satanistlav at mail dot ru
 ID:   35050
 User updated by:  satanistlav at mail dot ru
 Reported By:  satanistlav at mail dot ru
-Status:   Feedback
+Status:   Open
 Bug Type: Scripting Engine problem
 Operating System: Linux
 PHP Version:  5.0.5
 New Comment:

http://www.yda.com.tr/info.php


Previous Comments:


[2005-11-01 14:57:02] [EMAIL PROTECTED]

What is your locale set to? Can you provide a link to phpinfo() output?



[2005-11-01 14:45:44] satanistlav at mail dot ru

Description:

The Linux hosting server I use recently upgraded PHP Version to 5.0.4.
After upgrade all function and and class methods those had capital I
letter in the function names became unrecognized by PHP. No such
problem I had in previouse version of PHP, and no problem in my local
server (WinXP, Apache 2, PHP v5.0.5)

Reproduce code:
---
//Part of mail class
.
/**
 * Sets Mailer to send message using SMTP.
 * @return void
 */
   function IsSMTP() {
   $this-Mailer = smtp;
   }

/**
 * Sets Mailer to send message using PHP mail() function.
 * @return void
 */
function IsMail() {
$this-Mailer = mail;
}
.
/*  I used class methods ***/
 .
 $mailer-IsHtml(true);
 $mailer-IsMail();
 .

Expected result:

Execution of class method is expected

Actual result:
--
/* I got error /
Fatal error: Call to undefined method PHPMailer::IsHtml() in  





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


#35050 [Opn-Asn]: PHP 5 do not recognize Capital I letters in function and class method names

2005-11-01 Thread derick
 ID:   35050
 Updated by:   [EMAIL PROTECTED]
 Reported By:  satanistlav at mail dot ru
-Status:   Open
+Status:   Assigned
 Bug Type: Scripting Engine problem
 Operating System: Linux
 PHP Version:  5.0.5
-Assigned To:  
+Assigned To:  dmitry
 New Comment:

I can reproduce this with the following short script:

?php
class foo
{
function IsHere()
{
echo here\n;
}
}

echo setlocale(LC_ALL, 'tr_TR'), \n;

$f = new foo();
$f-IsHere();
?

(You need to have the tr_TR locale installed for this).

It does work properly with PHP 5.1 actually, and it has to to with the
zend_str_tolower() function which uses the tolower() libc call, which
uses the locale. As in Turkish the I does not lowercase to i you can
get weird things. This is why we should get rid of case insensitive
function names.

It also works with normal function names (instead of classes' methods)



Previous Comments:


[2005-11-01 15:02:31] satanistlav at mail dot ru

http://www.yda.com.tr/info.php



[2005-11-01 14:57:02] [EMAIL PROTECTED]

What is your locale set to? Can you provide a link to phpinfo() output?



[2005-11-01 14:45:44] satanistlav at mail dot ru

Description:

The Linux hosting server I use recently upgraded PHP Version to 5.0.4.
After upgrade all function and and class methods those had capital I
letter in the function names became unrecognized by PHP. No such
problem I had in previouse version of PHP, and no problem in my local
server (WinXP, Apache 2, PHP v5.0.5)

Reproduce code:
---
//Part of mail class
.
/**
 * Sets Mailer to send message using SMTP.
 * @return void
 */
   function IsSMTP() {
   $this-Mailer = smtp;
   }

/**
 * Sets Mailer to send message using PHP mail() function.
 * @return void
 */
function IsMail() {
$this-Mailer = mail;
}
.
/*  I used class methods ***/
 .
 $mailer-IsHtml(true);
 $mailer-IsMail();
 .

Expected result:

Execution of class method is expected

Actual result:
--
/* I got error /
Fatal error: Call to undefined method PHPMailer::IsHtml() in  





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


#35050 [Asn-Opn]: PHP 5 do not recognize Capital I letters in function and class method names

2005-11-01 Thread satanistlav at mail dot ru
 ID:   35050
 User updated by:  satanistlav at mail dot ru
 Reported By:  satanistlav at mail dot ru
-Status:   Assigned
+Status:   Open
 Bug Type: Scripting Engine problem
 Operating System: Linux
 PHP Version:  5.0.5
 Assigned To:  dmitry
 New Comment:

I have multilingual site. Locales are set to en_US.ISO-8859-1 in
Enlgish side of the site and tr_TR.ISO-8859-9 in Turkish for LC_ALL


Previous Comments:


[2005-11-01 15:12:29] [EMAIL PROTECTED]

I can reproduce this with the following short script:

?php
class foo
{
function IsHere()
{
echo here\n;
}
}

echo setlocale(LC_ALL, 'tr_TR'), \n;

$f = new foo();
$f-IsHere();
?

(You need to have the tr_TR locale installed for this).

It does work properly with PHP 5.1 actually, and it has to to with the
zend_str_tolower() function which uses the tolower() libc call, which
uses the locale. As in Turkish the I does not lowercase to i you can
get weird things. This is why we should get rid of case insensitive
function names.

It also works with normal function names (instead of classes' methods)




[2005-11-01 15:02:31] satanistlav at mail dot ru

http://www.yda.com.tr/info.php



[2005-11-01 14:57:02] [EMAIL PROTECTED]

What is your locale set to? Can you provide a link to phpinfo() output?



[2005-11-01 14:45:44] satanistlav at mail dot ru

Description:

The Linux hosting server I use recently upgraded PHP Version to 5.0.4.
After upgrade all function and and class methods those had capital I
letter in the function names became unrecognized by PHP. No such
problem I had in previouse version of PHP, and no problem in my local
server (WinXP, Apache 2, PHP v5.0.5)

Reproduce code:
---
//Part of mail class
.
/**
 * Sets Mailer to send message using SMTP.
 * @return void
 */
   function IsSMTP() {
   $this-Mailer = smtp;
   }

/**
 * Sets Mailer to send message using PHP mail() function.
 * @return void
 */
function IsMail() {
$this-Mailer = mail;
}
.
/*  I used class methods ***/
 .
 $mailer-IsHtml(true);
 $mailer-IsMail();
 .

Expected result:

Execution of class method is expected

Actual result:
--
/* I got error /
Fatal error: Call to undefined method PHPMailer::IsHtml() in  





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


#35050 [Opn]: PHP 5 do not recognize Capital I letters in function and class method names

2005-11-01 Thread satanistlav at mail dot ru
 ID:   35050
 User updated by:  satanistlav at mail dot ru
 Reported By:  satanistlav at mail dot ru
 Status:   Open
 Bug Type: Scripting Engine problem
 Operating System: Linux
 PHP Version:  5.0.5
 Assigned To:  dmitry
 New Comment:

I have uploaded your code to the server and I still have the same
error! http://www.yda.com.tr/test.php


Previous Comments:


[2005-11-01 15:14:14] satanistlav at mail dot ru

I have multilingual site. Locales are set to en_US.ISO-8859-1 in
Enlgish side of the site and tr_TR.ISO-8859-9 in Turkish for LC_ALL



[2005-11-01 15:12:29] [EMAIL PROTECTED]

I can reproduce this with the following short script:

?php
class foo
{
function IsHere()
{
echo here\n;
}
}

echo setlocale(LC_ALL, 'tr_TR'), \n;

$f = new foo();
$f-IsHere();
?

(You need to have the tr_TR locale installed for this).

It does work properly with PHP 5.1 actually, and it has to to with the
zend_str_tolower() function which uses the tolower() libc call, which
uses the locale. As in Turkish the I does not lowercase to i you can
get weird things. This is why we should get rid of case insensitive
function names.

It also works with normal function names (instead of classes' methods)




[2005-11-01 15:02:31] satanistlav at mail dot ru

http://www.yda.com.tr/info.php



[2005-11-01 14:57:02] [EMAIL PROTECTED]

What is your locale set to? Can you provide a link to phpinfo() output?



[2005-11-01 14:45:44] satanistlav at mail dot ru

Description:

The Linux hosting server I use recently upgraded PHP Version to 5.0.4.
After upgrade all function and and class methods those had capital I
letter in the function names became unrecognized by PHP. No such
problem I had in previouse version of PHP, and no problem in my local
server (WinXP, Apache 2, PHP v5.0.5)

Reproduce code:
---
//Part of mail class
.
/**
 * Sets Mailer to send message using SMTP.
 * @return void
 */
   function IsSMTP() {
   $this-Mailer = smtp;
   }

/**
 * Sets Mailer to send message using PHP mail() function.
 * @return void
 */
function IsMail() {
$this-Mailer = mail;
}
.
/*  I used class methods ***/
 .
 $mailer-IsHtml(true);
 $mailer-IsMail();
 .

Expected result:

Execution of class method is expected

Actual result:
--
/* I got error /
Fatal error: Call to undefined method PHPMailer::IsHtml() in  





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


#35050 [Opn-Asn]: PHP 5 do not recognize Capital I letters in function and class method names

2005-11-01 Thread derick
 ID:   35050
 Updated by:   [EMAIL PROTECTED]
 Reported By:  satanistlav at mail dot ru
-Status:   Open
+Status:   Assigned
 Bug Type: Scripting Engine problem
 Operating System: Linux
-PHP Version:  5.0.5
+PHP Version:  5CVS
 Assigned To:  dmitry
 New Comment:

Actually, PHP 5.1 gives the same broken result... but it works in 4.4.
Yes, we confirm there is a bug here - not sure how to fix it though)
Assigning to Dmitry for now. (Please don't switch the bug back to
Open)


Previous Comments:


[2005-11-01 15:17:54] satanistlav at mail dot ru

I have uploaded your code to the server and I still have the same
error! http://www.yda.com.tr/test.php



[2005-11-01 15:14:14] satanistlav at mail dot ru

I have multilingual site. Locales are set to en_US.ISO-8859-1 in
Enlgish side of the site and tr_TR.ISO-8859-9 in Turkish for LC_ALL



[2005-11-01 15:12:29] [EMAIL PROTECTED]

I can reproduce this with the following short script:

?php
class foo
{
function IsHere()
{
echo here\n;
}
}

echo setlocale(LC_ALL, 'tr_TR'), \n;

$f = new foo();
$f-IsHere();
?

(You need to have the tr_TR locale installed for this).

It does work properly with PHP 5.1 actually, and it has to to with the
zend_str_tolower() function which uses the tolower() libc call, which
uses the locale. As in Turkish the I does not lowercase to i you can
get weird things. This is why we should get rid of case insensitive
function names.

It also works with normal function names (instead of classes' methods)




[2005-11-01 15:02:31] satanistlav at mail dot ru

http://www.yda.com.tr/info.php



[2005-11-01 14:57:02] [EMAIL PROTECTED]

What is your locale set to? Can you provide a link to phpinfo() output?



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

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


#35052 [NEW]: $var-$arrayname['item'] fails

2005-11-01 Thread sam at liddicott dot com
From: sam at liddicott dot com
Operating system: Linux
PHP version:  4.4.0
PHP Bug Type: Scripting Engine problem
Bug description:  $var-$arrayname['item'] fails

Description:

Indirect object array access
$var-$arrayname['item']
only takes the first letter of the array name


Reproduce code:
---
?php # THIS FAILS
$name=list; 
$obj-$name['item']='test'; 
var_dump($obj); 
?

?php # THIS WORKS FINE
$name=list; 
$array=$obj-$name;
$array['item']='test'; 
var_dump($obj); 
?




Expected result:

object(stdClass)(1) {
  [list]=
  string(4) test
}


Actual result:
--
object(stdClass)(1) {
  [l]=
  string(4) test
}


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


#35009 [Fbk-Opn]: mysql_pconnect() crashes on PHP-CLI when ZTS is enabled

2005-11-01 Thread glen at delfi dot ee
 ID:   35009
 User updated by:  glen at delfi dot ee
 Reported By:  glen at delfi dot ee
-Status:   Feedback
+Status:   Open
 Bug Type: MySQL related
 Operating System: PLD Linux
 PHP Version:  5CVS-2005-10-28 (snap)
 New Comment:

yes. appears so: 
 
$ ./configure --disable-all --with-mysql 
--enable-maintainer-zts --enable-debug 
$ make 
$ ./sapi/cli/php  -r '$r = mysql_pconnect(heart);echo 
$r\n;'; echo rc=$? 
Resource id #4 
rc=0 
$ ./sapi/cli/php -m 
[PHP Modules] 
date 
mysql 
standard 
 
[Zend Modules] 
 
code used: php5-200510281630


Previous Comments:


[2005-11-01 11:39:45] [EMAIL PROTECTED]

What if you configure the mysql extension as static, does it work then?



[2005-10-28 20:49:51] glen at delfi dot ee

same thing with php5-200510281630

$ ./sapi/cli/php -v
PHP 5.1.0RC5-dev (cli) (built: Oct 28 2005 21:47:13) (DEBUG)
Copyright (c) 1997-2005 The PHP Group
Zend Engine v2.1.0-dev, Copyright (c) 1998-2005 Zend Technologies

$ ./sapi/cli/php  -r 'dl(mysql.so); mysql_pconnect();'

Warning: mysql_pconnect(): Can't connect to local MySQL server through
socket '/var/lib/mysql/mysql.sock' (2) in Command line code on line 1
/home/builder/rpm/BUILD/php5-200510281630/Zend/zend_hash.c(678) :
ht=0x8264d78 is already destroyed
/home/builder/rpm/BUILD/php5-200510281630/Zend/zend_hash.c(678) :
ht=0x8264d78 is already destroyed
/home/builder/rpm/BUILD/php5-200510281630/Zend/zend_hash.c(67) : Bailed
out without a bailout address!
$



[2005-10-28 19:54:46] [EMAIL PROTECTED]

Please try using this CVS snapshot:

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





[2005-10-28 19:08:22] glen at delfi dot ee

ok. this is quick way to see it, altho the error is different.

$ ./configure --disable-all --with-mysql=shared --enable-maintainer-zts
--enable-debug
$ make
$ ./sapi/cli/php  -i |grep -i safe
$ sudo mkdir -p /usr/local/lib/php/extensions/debug-zts-20041030/
$ sudo chown builder /usr/local/lib/php/extensions/debug-zts-20041030/
$ cp modules/mysql.so
/usr/local/lib/php/extensions/debug-zts-20041030/
$ ./sapi/cli/php  -r 'dl(mysql.so); mysql_pconnect();'
Warning: mysql_pconnect(): Can't connect to local MySQL server through
socket '/var/lib/mysql/mysql.sock' (2) in Command line code on line 1
/home/builder/rpm/BUILD/p/php5-STABLE-200510281434/Zend/zend_hash.c(678)
: ht=0x9ce4a74 is already destroyed
/home/builder/rpm/BUILD/p/php5-STABLE-200510281434/Zend/zend_hash.c(678)
: ht=0x9ce4a74 is already destroyed
/home/builder/rpm/BUILD/p/php5-STABLE-200510281434/Zend/zend_hash.c(67)
: Bailed out without a bailout address!
$



[2005-10-28 19:05:48] glen at delfi dot ee

Description:

$ php -r 'mysql_pconnect();'
Segmentation fault

you will need to specify proper auth strings for the connection to
succeed.

bug is present in php 4.4.0, php 5.0.5 with both ZTS enabled. on same
system disabling ZTS with php 4.4.0 the crash didn't occour.

also used php5-STABLE-200510281434 snapshot. and crash was
reproducible.


Reproduce code:
---
$ gdb --args php -r 'mysql_pconnect();'
GNU gdb 6.3
Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and
you are
welcome to change it and/or distribute copies of it under certain
conditions.
Type show copying to see the conditions.
There is absolutely no warranty for GDB.  Type show warranty for
details.
This GDB was configured as --host= --target=i686-pld-linux...Using
host libthread_db library /lib/tls/libthread_db.so.1.

(gdb) run
Starting program: /usr/bin/php -r mysql_pconnect\(\)\;

Program received signal SIGSEGV, Segmentation fault.
0xb7879948 in ?? ()
(gdb) bt
#0  0xb7879948 in ?? ()
#1  0xb7f0d549 in plist_entry_destructor (ptr=0x80dbb00)
at
/home/builder/rpm/BUILD/php5-STABLE-200510281434/Zend/zend_list.c:210
#2  0xb7f0b53f in zend_hash_apply_deleter (ht=0x8052c60, p=0x80e3f40)
at
/home/builder/rpm/BUILD/php5-STABLE-200510281434/Zend/zend_hash.c:574
#3  0xb7f0b790 in zend_hash_graceful_reverse_destroy (ht=0x8052c60)
at
/home/builder/rpm/BUILD/php5-STABLE-200510281434/Zend/zend_hash.c:640
#4  0xb7f0d665 in zend_destroy_rsrc_list (ht=0x8052c60,
tsrm_ls=0x804f0a8)
at
/home/builder/rpm/BUILD/php5-STABLE-200510281434/Zend/zend_list.c:240
#5  0xb7f0146a in zend_shutdown (tsrm_ls=0x804f0a8) at
/home/builder/rpm/BUILD/php5-STABLE-200510281434/Zend/zend.c:714
#6  0xb7eaa3e3 in php_module_shutdown (tsrm_ls=0x804f0a8)
at
/home/builder/rpm/BUILD/php5-STABLE-200510281434/main/main.c:1529
#7  0x0804be44 in main (argc=3, 

#35053 [NEW]: === is wrong for objects and also stupid

2005-11-01 Thread sam at liddicott dot com
From: sam at liddicott dot com
Operating system: Linux
PHP version:  4.4.0
PHP Bug Type: Scripting Engine problem
Bug description:  === is wrong for objects and also stupid

Description:

=== does not compare two objects for identity, it compares the values of
their fields, and recursively at that! It gives wrong answers and in some
cases fails altogether!

Would you believe that === reports two different objects as being the same
object, when they are not references?

Why can't it just check if they have the same storage address, that should
be quick, painless and accurate!

There should be some way to tell when two object references refer to the
same object (apart hack in an extra field and see if it appears in the
other)

Reproduce code:
---
?php

$t-name='t';
$e-name='e';

$t-e=$e;
$e-t=$t;

$tt=$t;

$a-n='n';
$b-n='n';

if ($a===$b) print Dear me A and B are the same\n;
else print Of course A and B are different\n;

if ($tt===$t) print Yes, of course TT and T are the same\n;
else print No they are not\n;
?


Expected result:

Of course A and B are different
Yes, of course TT and T are the same

Actual result:
--
Dear me A and B are the same

Fatal error: Nesting level too deep - recursive dependency? in
/home/sam/projects/reporter/t.php on line 17


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


#35053 [Opn-WFx]: === is wrong for objects and also stupid

2005-11-01 Thread derick
 ID:   35053
 Updated by:   [EMAIL PROTECTED]
 Reported By:  sam at liddicott dot com
-Status:   Open
+Status:   Wont fix
 Bug Type: Scripting Engine problem
 Operating System: Linux
 PHP Version:  4.4.0
 New Comment:

We can not change this behavior, as this might break existing scripts.



Previous Comments:


[2005-11-01 17:02:32] sam at liddicott dot com

Description:

=== does not compare two objects for identity, it compares the values
of their fields, and recursively at that! It gives wrong answers and in
some cases fails altogether!

Would you believe that === reports two different objects as being the
same object, when they are not references?

Why can't it just check if they have the same storage address, that
should be quick, painless and accurate!

There should be some way to tell when two object references refer to
the same object (apart hack in an extra field and see if it appears in
the other)

Reproduce code:
---
?php

$t-name='t';
$e-name='e';

$t-e=$e;
$e-t=$t;

$tt=$t;

$a-n='n';
$b-n='n';

if ($a===$b) print Dear me A and B are the same\n;
else print Of course A and B are different\n;

if ($tt===$t) print Yes, of course TT and T are the same\n;
else print No they are not\n;
?


Expected result:

Of course A and B are different
Yes, of course TT and T are the same

Actual result:
--
Dear me A and B are the same

Fatal error: Nesting level too deep - recursive dependency? in
/home/sam/projects/reporter/t.php on line 17






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


#35051 [Opn-Bgs]: Problem with empty()

2005-11-01 Thread storm at mail dot up dot com dot ua
 ID:   35051
 User updated by:  storm at mail dot up dot com dot ua
 Reported By:  storm at mail dot up dot com dot ua
-Status:   Open
+Status:   Bogus
 Bug Type: Scripting Engine problem
 Operating System: FreeBsd 5.3
 PHP Version:  5.0.5
 New Comment:

Sorry. Zend optimizer


Previous Comments:


[2005-11-01 14:57:12] storm at mail dot up dot com dot ua

Description:

Various results empty() for nonexistent key 

Reproduce code:
---
$w=array('a'='','b'=array('dd'=1,'aa'=2));

foreach($w as $k=$v)
{
if(empty($v['dd']))
echo {$k}:emptybr\n;
else
echo {$k}:no emptybr\n;
}


Expected result:

a:emptybr  
b:no emptybr

(PHP 5.03 FreeBsd 4.9)

Actual result:
--
a:no emptybr  
b:no emptybr

(PHP 5.05 FreeBsd 5.3)





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


#35040 [Com]: slowness and timeouts when using php-4.4.1

2005-11-01 Thread gabe at mudbugmedia dot com
 ID:   35040
 Comment by:   gabe at mudbugmedia dot com
 Reported By:  sbailey at mileone dot com
 Status:   Feedback
 Bug Type: Performance problem
 Operating System: FreeBSD 5.3
 PHP Version:  4.4.1RC1
 New Comment:

I haven't managed to discover if this is a SquirrelMail bug or 
a PHP bug, but the change from 4.4.0 to 4.4.1 definitely 
causes the break down.

A bug report with a work around is available at SquirrelMail's 
sourceforge page. http://sourceforge.net/tracker/index.php?
func=detailaid=1344216group_id=311atid=100311 .  The work 
around is to turn on server side sorting (in your config.php 
file) to prevent the effected function from being called.


Previous Comments:


[2005-10-31 21:35:21] vmlinuz386 at yahoo dot com dot ar

I have the same problem, but running on apache-1.3.34 (Linux), with the
php-4.4.1, i am back to php-4.4.0 and this fixes.
Here is the phpinfo() http://www.vmlinuz.com.ar/phpinfo.php

Squirrelmail is 1.4.5, can browse all pages, but the problem  appear
when open a message.

Another problem is that httpd takes many more seconds to stop with
4.4.1, not with 4.4.0.



[2005-10-31 21:13:21] [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.




[2005-10-31 20:53:39] sbailey at mileone dot com

Description:

Installed a fresh install of php-4.4.1 and the only compile options
were --with-apxs2 and I am running apache 2.0.55 on FreeBSD 5.3 and
when I run SquirrelMail version 1.4.5 httpd takes alot of system
resources and is really slow.  I can provide more info if nessary.

Thanks






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


#31594 [Fbk-Opn]: virtual(): Unable to include 'xxx' - error finding URI

2005-11-01 Thread per at computer dot org
 ID:   31594
 User updated by:  per at computer dot org
 Reported By:  per at computer dot org
-Status:   Feedback
+Status:   Open
 Bug Type: Apache2 related
 Operating System: linux 2.4.26
 PHP Version:  5.*, 4.*
 New Comment:

Oops, sorry about that.  Have now tried
http://snaps.php.net/php5-latest.tar.gz - no change, problem remains.


Previous Comments:


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

Please use the EXACT same url's as asked to. You were asked to try the
latest, not 'stable'.





[2005-10-22 13:10:28] per at computer dot org

I should add - I am now getting a line with no acceptable variant:
for part1 in my apache2 error-log.



[2005-10-22 13:05:20] per at computer dot org

Ran my testcase using php5-STABLE-200510220840 - it still fails:

part0+
Warning: virtual() [function.virtual]: Unable to include 'part1' -
error finding URI in
/srv/www/vhosts/www/htdocs/phpbug-31594/part0.phtml on line 11



[2005-10-19 17:24:00] [EMAIL PROTECTED]

Please try using this CVS snapshot:

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





[2005-09-14 08:38:04] per at computer dot org

Actually no - apache content negotiation takes care of that.  Also, as
discussed earlier, the example works fine in php 4.3.8.



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

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


#35048 [Fbk-Opn]: parse_ini_file will be influenced by putenv in special situation

2005-11-01 Thread liber at iproom dot com
 ID:   35048
 User updated by:  liber at iproom dot com
 Reported By:  liber at iproom dot com
-Status:   Feedback
+Status:   Open
 Bug Type: *General Issues
 Operating System: Windows XP
 PHP Version:  5.0.5
 New Comment:

I have try the latest PHP version (5.1.0 RC 5-dev)
The situation is the same.

Only if I disable the putenv command to stop put 'TZ' data,
then everything is normal.

When I re-enable to put 'TZ' by putenv, the error occur again.

And I forgot to say, additional, the apache2 will crash with this error
sometimes.


Previous Comments:


[2005-11-01 14:27:35] [EMAIL PROTECTED]

Please try using this CVS snapshot:

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





[2005-11-01 13:39:37] liber at iproom dot com

Description:

First, var_dump the result read by parse_ini_file is:
array (
  'dbHost' = 'localhost',
  'dbUser' = 'mmcwebapp',
  'dbPassword' = '',
  'dbName' = 'faraday',
)

but i don't know why, everytime after
the command: putenv(TZ=);

the result will change as follow:

array (
  'dbHost' = 'localhost',
  'dbUser' = 'mmcwebapp',
  'dbPassword' = '',
  'faradayc8XC9-2' = 'faraday',
)

I can't not figure out where problem is,
then I use Zend Studio and add a watch like this

var_export(parse_ini_file(DBX_CONFIG_FILE),1)

the DBX_CONFIG_FILE is defined as like as c:\a.ini

then I saw the changing in debug mode(step by step).






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


#35034 [Bgs]: $this != ($this)

2005-11-01 Thread olympic at dino-online dot de
 ID:   35034
 User updated by:  olympic at dino-online dot de
 Reported By:  olympic at dino-online dot de
 Status:   Bogus
 Bug Type: Feature/Change Request
 Operating System: *nix
 PHP Version:  5.0.5
 New Comment:

Following your comment:

$a=new Foo();
$b=$a ; // $b references $a
$c=($a); //$c is now a copy because only variables
are referencable ? (NOPE)

Well, seems a little bitte inconsistent for me, why
different behaviours in assignment and method calls ?


Previous Comments:


[2005-10-31 12:58:26] [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

($this) is an expression, not a variable, thus you can not pass it by
reference.



[2005-10-31 12:00:17] olympic at dino-online dot de

Description:

$this is treated as references, while ($this) not...

$this != ($this) ?? omg :)


Reproduce code:
---
error_reporting(E_ALL);

class Bar {
function onlyByRefPlease($foo) {
// ...
}
functionsomeMemberFunc1() {
$this-onlyByRefPlease($this);
}
functionsomeMemberFunc2() {
$this-onlyByRefPlease(($this)); // note: 2 Braces!
}
};

$foo = new Bar();
$foo-someMemberFunc1();
$foo-someMemberFunc2(); // throws error


Expected result:

/* none */

Actual result:
--
Fatal error: Only variables can be passed by reference in
/www/v3.evalanche.com/web/php_refbug.php on line 13





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


#35053 [WFx]: === is wrong for objects and also stupid

2005-11-01 Thread sam at liddicott dot com
 ID:   35053
 User updated by:  sam at liddicott dot com
 Reported By:  sam at liddicott dot com
 Status:   Wont fix
 Bug Type: Scripting Engine problem
 Operating System: Linux
 PHP Version:  4.4.0
 New Comment:

Well why not add a new operator  that does the job properly?

Or a function getAddressOfObject (a 5 liner, surely) that returns the
address of the object so a numeric compare can be done, or something
that does the job that needs doing?

Sam


Previous Comments:


[2005-11-01 17:06:31] [EMAIL PROTECTED]

We can not change this behavior, as this might break existing scripts.




[2005-11-01 17:02:32] sam at liddicott dot com

Description:

=== does not compare two objects for identity, it compares the values
of their fields, and recursively at that! It gives wrong answers and in
some cases fails altogether!

Would you believe that === reports two different objects as being the
same object, when they are not references?

Why can't it just check if they have the same storage address, that
should be quick, painless and accurate!

There should be some way to tell when two object references refer to
the same object (apart hack in an extra field and see if it appears in
the other)

Reproduce code:
---
?php

$t-name='t';
$e-name='e';

$t-e=$e;
$e-t=$t;

$tt=$t;

$a-n='n';
$b-n='n';

if ($a===$b) print Dear me A and B are the same\n;
else print Of course A and B are different\n;

if ($tt===$t) print Yes, of course TT and T are the same\n;
else print No they are not\n;
?


Expected result:

Of course A and B are different
Yes, of course TT and T are the same

Actual result:
--
Dear me A and B are the same

Fatal error: Nesting level too deep - recursive dependency? in
/home/sam/projects/reporter/t.php on line 17






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


#34978 [Opn-Asn]: php out of memory or segmentation fault while installing sugarcrm 3.5.1a

2005-11-01 Thread sniper
 ID:   34978
 Updated by:   [EMAIL PROTECTED]
 Reported By:  cdc at ccicon dot com
-Status:   Open
+Status:   Assigned
 Bug Type: Scripting Engine problem
 Operating System: linux i386
 PHP Version:  5.0.5
 Assigned To:  dmitry


Previous Comments:


[2005-11-01 13:52:28] cdc at ccicon dot com

I have tried to locate the exact code triggering the bug but have so
far been unsuccessfull.  So, I have been unable to come up with a
simple test case.  The bug is easily reproducible by trying to load and
run the Sugar code available here 
http://www.sugarforge.org/frs/download.php/466/SugarSuite-3.5.1a.zip

I can tell you that the bug still existed in the following CVS
snapshot.

php5-200510251830

If you believe that it might have been fixed in a newer snapshot, I
would be happy to test it.  Just point me at it.

TTYL
  CDC



[2005-11-01 13:40:27] [EMAIL PROTECTED]

Can anybody provide a test case?
May be this bug already fixed in HEAD and PHP_5_1.



[2005-11-01 11:41:27] [EMAIL PROTECTED]

This is really critical issue. Obviously that stupid compatibility
mode misbehaves still?



[2005-10-27 19:10:23] cdc at ccicon dot com

The zend.ze_compatiblity_mode is set to 1 in the index.php file and
several other files using the following test for php version number

if (substr(phpversion(), 0, 1) == 5) {
ini_set(zend.ze1_compatibility_mode, 1);
}

Disabling this option (ie zend.ze_compatiblity_mode=0) under php 5.0.5
and under the last cvs snapshot that was recommended seems to solve
this race condition.  I have not tested the code fully to see that this
hasn't introduced other problems.  However, it does remove the out of
memory and segfault problems.

Were there changes made in php 5.0.5 and later that make this option
obsolete.  Or, will disabling this condition lead to other compatility
issues?

TTYL
  CDC



[2005-10-27 18:53:57] cdc at ccicon dot com

I assume you meant ze1_compatiblity_mode and compact was just a typo? 
Yes compatibility_mode is set.  It is explicitly set numerous places
within the Sugar Code.  I can try changing it, but I'm assuming it was
set within the code for a reason.

I'll try changing it and see what happens.



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

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


#35054 [NEW]: Heavy Random Lag During foreach loop

2005-11-01 Thread starcitsura at shaw dot ca
From: starcitsura at shaw dot ca
Operating system: Linux
PHP version:  4.4.1RC1
PHP Bug Type: Performance problem
Bug description:  Heavy Random Lag During foreach loop

Description:

For some reason there is random lag when echoing the results.
Now I say random lightly because there seems to be a tendency for certain
items to be more likely to slow down then others, for instance at one
point I ran the script about 10 times, and item six in the list always
slowed down.

The lag seemed to occur inside the part that echoed each image and link,
at that time the lag would only occur on the image for the down button
which makes even less sense.
I used a micro time function that would echo the time since the last one
was called. The lag seemed to occur during the html portion of the code.,
which doesn’t make much sense to me.

What is causing this lag? I have also written the code so that it echo’s
the html instead of the way its done now, there was no effect on the lag

I wouldn't be worried about it if it was only like 15 milliseconds
difference, but the lag varies anywhere from 100 ms to 1500ms which is not
acceptable. Some time’s the list is as long as 100 items, in which case the
items with lag are much more common, causing the script to take as long a
1ms.

I have tested this script on two different servers, the lag occurs on
both.
The main server uses PHP 4.3.11


Reproduce code:
---
foreach($array as $value)
{
  $conID = substr($value, 1);
  switch ($value{0})
  {   #simply choses which mysql query to run, then runs it  }
  list($name,$built) = $data;
  $data = new entity($name);
  $cost = $data-fetchField('Cost'); ?
li?=$name;? (?=($cost-$built);?/?=$cost;?)
a href=?LID=?=$LID;?amp;conID=?=$value{0}.$conID;?amp;shift=up
title=Up
img alt=Up src=../../images/ingame/map/up.gif height=11 width=11
//a
a href=?LID=?=$LID;?amp;conID=?=$value{0}.$conID;?amp;shift=x
title=Cancel
img alt=Cancel src=../../images/ingame/map/x.gif height=11
width=11 //a
/li
?php
}



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


#34904 [Bgs]: Relocation error in libphp5.so when starting Apache2

2005-11-01 Thread sean dot healey at bayernlb dot co dot uk
 ID:   34904
 User updated by:  sean dot healey at bayernlb dot co dot uk
 Reported By:  sean dot healey at bayernlb dot co dot uk
 Status:   Bogus
 Bug Type: Sybase-ct (ctlib) related
 Operating System: Solaris 8
 PHP Version:  5.0.5
 New Comment:

No, perhaps not a bug with PHP itself, but definitely an issue with the
build process!!

You telling me you're just going to leave Solaris users who need Sybase
support swinging in the breeze?

I strongly suspect the problem is to do with GCC - which uses the
non-Sybase version of the libintl library, but haven't had time to
investigate further.


Previous Comments:


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

This still isn't PHP bug.




[2005-10-27 18:46:49] sean dot healey at bayernlb dot co dot uk

Just another thing to note: The following message appears during 'make
install' ...

libtool: install: warning: remember to run `libtool --finish
/var/build/php-5.0.5/libs'

I would expect to see the message ...

--
Libraries have been installed in:
   /var/build/php-5.0.5/libs

If you ever happen to want to link against installed libraries
in a given directory, LIBDIR, you must either use libtool, and
specify the full pathname of the library, or use the `-LLIBDIR'
flag during linking and do at least one of the following:
   - add LIBDIR to the `LD_LIBRARY_PATH' environment variable
 during execution
   - use the `-RLIBDIR' linker flag

See any operating system documentation about shared libraries for
more information, such as the ld(1) and ld.so(8) manual pages.
--

... during the install phase, but this is missing. I presume this is
purely informational?

Sorry - I know this is unrelated to the above, just thought I should
bring it to your attention.



[2005-10-27 18:18:23] sean dot healey at bayernlb dot co dot uk

I have managed to get around the build problem by sym-linking
libintl.so - libintl.so.1 in the Sybase libraries path. Apache2 now
starts with the php5 module configured.

This seems to me to be an issue with the PHP build - we have no such
problems compiling other CTLIB applications!

Please note - the 'duplicate' name of the libintl library is NOT
Sybase's problem. Sybase support say that they created that library
'years' before Solaris introduced one of the same name.

Bittersweet victory though, because now sybase_connect() won't connect
despite the interfaces file being present, correct and configured in
php.ini.



[2005-10-27 11:30:54] sean dot healey at bayernlb dot co dot uk

Whoah! Please don't be misled by the configure script I submitted in
this bug report - the LDFLAGS and CPPFLAGS variables were set during my
attempts to work around the problem because I originally thought that
the build was picking up the wrong libtcl.so. I have since verified
that the only copies of this library on my system are under the Sybase
paths.

It does appear that the wrong libintl.so library is being picked up -
it should be using the one under the Sybase path, but is ignoring it
and using the one under /usr/lib instead.

I have tried this build against both the Sybase 12.0 and 12.5 client
libraries with identical results.

My original configure script is:

#!/usr/bin/sh

DSQUERY=fx_dbserver2_ds
SYBASE=/dpkg/sybase/sybase12_5
SYBASE_OCS=OCS-12_5
LD_LIBRARY_PATH=$SYBASE/$SYBASE_OCS/lib:/usr/local/lib:$LD_LIBRARY_PATH
PATH=/usr/ccs/bin:$PATH

export DSQUERY SYBASE SYBASE_OCS LD_LIBRARY_PATH PATH

cd php-5.0.5

./configure \
  --prefix=/usr/local/php \
  --with-apxs2=/usr/local/apache2/bin/apxs \
  --with-sybase-ct=$SYBASE/$SYBASE_OCS \
  --without-bz2

This produces a libphp5.so which is linked as follows:

ldd /usr/local/apache2/modules/libphp5.so
libtcl.so =
/dpkg/sybase/sybase12_5/OCS-12_5/lib/libtcl.so
libintl.so.1 =  /usr/lib/libintl.so.1
libcomn.so =   
/dpkg/sybase/sybase12_5/OCS-12_5/lib/libcomn.so
libct.so =  /dpkg/sybase/sybase12_5/OCS-12_5/lib/libct.so
libcs.so =  /dpkg/sybase/sybase12_5/OCS-12_5/lib/libcs.so
libresolv.so.2 =/usr/lib/libresolv.so.2
libm.so.1 = /usr/lib/libm.so.1
libdl.so.1 =/usr/lib/libdl.so.1
libnsl.so.1 =   /usr/lib/libnsl.so.1
libsocket.so.1 =/usr/lib/libsocket.so.1
libz.so.1 = /usr/lib/libz.so.1
libxml2.so.2 =  /usr/local/lib/libxml2.so.2
libiconv.so.2 = /usr/local/lib/libiconv.so.2
libc.so.1 = /usr/lib/libc.so.1
libmp.so.2 =/usr/lib/libmp.so.2
libpthread.so.1 =   /usr/lib/libpthread.so.1

#35052 [Opn-Bgs]: $var-$arrayname['item'] fails

2005-11-01 Thread tony2001
 ID:   35052
 Updated by:   [EMAIL PROTECTED]
 Reported By:  sam at liddicott dot com
-Status:   Open
+Status:   Bogus
 Bug Type: Scripting Engine problem
 Operating System: Linux
 PHP Version:  4.4.0
 New Comment:

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

$this-var is the right syntax for that.


Previous Comments:


[2005-11-01 15:46:33] sam at liddicott dot com

Description:

Indirect object array access
$var-$arrayname['item']
only takes the first letter of the array name


Reproduce code:
---
?php # THIS FAILS
$name=list; 
$obj-$name['item']='test'; 
var_dump($obj); 
?

?php # THIS WORKS FINE
$name=list; 
$array=$obj-$name;
$array['item']='test'; 
var_dump($obj); 
?




Expected result:

object(stdClass)(1) {
  [list]=
  string(4) test
}


Actual result:
--
object(stdClass)(1) {
  [l]=
  string(4) test
}






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


#35037 [Asn-Csd]: unknown data type (36)

2005-11-01 Thread fmk
 ID:   35037
 Updated by:   [EMAIL PROTECTED]
 Reported By:  spooky at int13h dot com
-Status:   Assigned
+Status:   Closed
 Bug Type: MSSQL related
 Operating System: FreeBSD 5.4
 PHP Version:  5CVS-2005-10-31 (snap)
 Assigned To:  fmk
 New Comment:

This bug has been fixed in CVS.

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




Previous Comments:


[2005-11-01 11:38:06] [EMAIL PROTECTED]

Frank, can you check this out please?




[2005-10-31 18:11:49] spooky at int13h dot com

Description:

For php5-200510311530 (Also 5.0.5 stable release)

./configure --prefix=/usr/local --with-apxs=/usr/local/apache/bin/apxs
--with-libxml-dir=/usr/local 
--with-zlib 
--with-curl 
--with-gd 
--with-ldap 
--with-mssql
--with-pear

For FreeTDS 0.63 
./configure --prefix=/usr/local 
--with-tdsver=8.0
--enable-msdblib

When I fire an SQL Query that returns a uniqueidentifier I get the
error 'Warning: mssql_query() [function.mssql-query]: column 1 has
unknown data type (36) in /usr/websites/dev/testies.php on line 12'

Reproduce code:
---
function connect_sql ()
{
   $mssql_link = mssql_connect('IP', 'USER','PASSWORD') or die
(Server Connection Error);
   $mssql_db = mssql_select_db('Websites',$mssql_link) or die(Database
Error);
}

connect_sql();

$query = 'select newid() as test';
echo $query . 'br/';
mssql_query($query);
mssql_close();

Expected result:

No result should be returned. It should generate a new id.

Actual result:
--
'Warning: mssql_query() [function.mssql-query]: column 1 has unknown
data type (36) in /usr/websites/dev/testies.php on line 12'





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


#35056 [NEW]: Apache2 child crashes if ErrorDocument is PHP script

2005-11-01 Thread margus at zone dot ee
From: margus at zone dot ee
Operating system: SuSE Linux 9.0
PHP version:  4.4.1RC1
PHP Bug Type: Reproducible crash
Bug description:  Apache2 child crashes if ErrorDocument is PHP script

Description:

I have PHP compiled as apache2handler SAPI and using ErrorDocument, which
points to an PHP script. If this ErrorDocument is triggered, then apache
child crashes.

It must be connected with the bug #33987
and as ironic it is, PHP 4.4.1 Changelog claims, that #33987  is fixed.
Bug #33987 is actually reported against PHP5.1 and not against 4.4.0. PHP
4.4.0 works fine with ErrorDocuments.

-

I looked into the apache2handler source
(sapi/apache2handler/sapi_apache2.c) and after debugging it was clear,
that crash happens on line (538):

   if (parent_req  strcmp(parent_req-handler, PHP_MAGIC_TYPE) 
strcmp(parent_req-handler, PHP_SOURCE_MAGIC_TYPE) 
strcmp(parent_req-handler, PHP_SCRIPT)) {

If changed to this:

   if (parent_req  parent_req-handler  strcmp(parent_req-handler,
PHP_MAGIC_TYPE)  strcmp(parent_req-handler, PHP_SOURCE_MAGIC_TYPE) 
strcmp(parent_req-handler, PHP_SCRIPT)) {

then everything's fine and works.

The correct extra check is present in 5.1.0 (but for some odd reason not
in 4.4.1 and 5.0.5).

Reproduce code:
---
.htaccess
-
ErrorDocument 404 /error.php?status=404

/error.php
-
die( File Not Found! );


Expected result:

File Not Found!

Actual result:
--
Apache2 crashes.

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


#35057 [NEW]: abstract method inheritance and interface implementation problem

2005-11-01 Thread antonsub at pochtamt dot ru
From: antonsub at pochtamt dot ru
Operating system: Linux
PHP version:  5.1.0RC4
PHP Bug Type: Scripting Engine problem
Bug description:  abstract method inheritance and interface implementation 
problem

Description:

Code given produces fatal error:
Can't inherit abstract function A::foo() (previously declared abstract in
B) in foo.php on line 20

Reproduce code:
---
?php
interface A
{
public function foo($id);
}

abstract class B
{
abstract public function foo($id);
}

class C extends B
{
public function foo($id)
{
echo foo\n;
}
}

class D extends C implements A {}

var_dump(new D);
?


Expected result:

But is expected to run cleanly.


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


#35058 [NEW]: server abend using spl_autoload and friends

2005-11-01 Thread [EMAIL PROTECTED]
From: [EMAIL PROTECTED]
Operating system: windows 2000
PHP version:  5.1.0RC4
PHP Bug Type: SPL related
Bug description:  server abend using spl_autoload and friends

Description:

Similar to http://bugs.php.net/bug.php?id=34216 I am experiencing
intermitent server abends while trying to integrate some of the new
spl_autoload_* functionality in a custom application on apache 1.3.33. In
particular, I am using spl to register a static class method that
implements its own polymorphic autoload behaviours. The custom class
loader is known to work well if called directly from __autoload.

It also appears that all documentation for (and mention of) spl_autoload_*
has disappeared. Is this still intended for 5.1 and/or are their plans to
integrate this into the engine -- where it belongs?


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


#35056 [Com]: Apache2 child crashes if ErrorDocument is PHP script

2005-11-01 Thread sebastian dot harnau at gmx dot de
 ID:   35056
 Comment by:   sebastian dot harnau at gmx dot de
 Reported By:  margus at zone dot ee
 Status:   Open
 Bug Type: Reproducible crash
 Operating System: SuSE Linux 9.0
 PHP Version:  4.4.1RC1
 New Comment:

Same Problem here (SuSE 9.2), Solution works for me, too!


Previous Comments:


[2005-11-01 20:25:57] margus at zone dot ee

Description:

I have PHP compiled as apache2handler SAPI and using ErrorDocument,
which points to an PHP script. If this ErrorDocument is triggered, then
apache child crashes.

It must be connected with the bug #33987
and as ironic it is, PHP 4.4.1 Changelog claims, that #33987  is fixed.
Bug #33987 is actually reported against PHP5.1 and not against 4.4.0.
PHP 4.4.0 works fine with ErrorDocuments.

-

I looked into the apache2handler source
(sapi/apache2handler/sapi_apache2.c) and after debugging it was clear,
that crash happens on line (538):

   if (parent_req  strcmp(parent_req-handler, PHP_MAGIC_TYPE) 
strcmp(parent_req-handler, PHP_SOURCE_MAGIC_TYPE) 
strcmp(parent_req-handler, PHP_SCRIPT)) {

If changed to this:

   if (parent_req  parent_req-handler  strcmp(parent_req-handler,
PHP_MAGIC_TYPE)  strcmp(parent_req-handler, PHP_SOURCE_MAGIC_TYPE) 
strcmp(parent_req-handler, PHP_SCRIPT)) {

then everything's fine and works.

The correct extra check is present in 5.1.0 (but for some odd reason
not in 4.4.1 and 5.0.5).

Reproduce code:
---
.htaccess
-
ErrorDocument 404 /error.php?status=404

/error.php
-
die( File Not Found! );


Expected result:

File Not Found!

Actual result:
--
Apache2 crashes.





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


#35057 [Opn-Bgs]: abstract method inheritance and interface implementation problem

2005-11-01 Thread helly
 ID:   35057
 Updated by:   [EMAIL PROTECTED]
 Reported By:  antonsub at pochtamt dot ru
-Status:   Open
+Status:   Bogus
 Bug Type: Scripting Engine problem
 Operating System: Linux
 PHP Version:  5.1.0RC4
 New Comment:

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

B::foo is not A::foo, so when C inherits B it gets B::foo and when it
implements A it gets A:foo, obviously A::foo and B::foo are different.
That's what the error tells you.


Previous Comments:


[2005-11-01 21:12:39] antonsub at pochtamt dot ru

Description:

Code given produces fatal error:
Can't inherit abstract function A::foo() (previously declared abstract
in B) in foo.php on line 20

Reproduce code:
---
?php
interface A
{
public function foo($id);
}

abstract class B
{
abstract public function foo($id);
}

class C extends B
{
public function foo($id)
{
echo foo\n;
}
}

class D extends C implements A {}

var_dump(new D);
?


Expected result:

But is expected to run cleanly.






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


#35059 [NEW]: Problems with PHP 4.4.1 and mod_rewrite

2005-11-01 Thread free4cd at yahoo dot de
From: free4cd at yahoo dot de
Operating system: SuSE 9.3
PHP version:  4.4.1RC1
PHP Bug Type: Apache2 related
Bug description:  Problems with PHP 4.4.1 and mod_rewrite

Description:

After updating two different webservers to PHP 4.4.1 I get always a blank
page with PHP 4.4.1 and mod_rewrite if you click on a link.
Start page load normal but on every additional page you see nothing. No
error in error log. Happens with vBulletin and mod_rewrite and Joomla
1.0.3 with mod_rewrite enabled and apache 2.0.55. With PHP 4.4.0 and same
settings in php.ini there are no problems. Only PHP version has
changed

Reproduce code:
---
Install Joomla 1.0.3 and use mod_rewrite and apache 2.0.x. Enable SEO in
Joomla.

Settings in .htaccess:

RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*) index.php



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


#35056 [Opn-Csd]: Apache2 child crashes if ErrorDocument is PHP script

2005-11-01 Thread iliaa
 ID:   35056
 Updated by:   [EMAIL PROTECTED]
 Reported By:  margus at zone dot ee
-Status:   Open
+Status:   Closed
 Bug Type: Reproducible crash
 Operating System: SuSE Linux 9.0
 PHP Version:  4.4.1RC1
 New Comment:

This bug has been fixed in CVS.

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




Previous Comments:


[2005-11-01 21:53:00] sebastian dot harnau at gmx dot de

Same Problem here (SuSE 9.2), Solution works for me, too!



[2005-11-01 20:25:57] margus at zone dot ee

Description:

I have PHP compiled as apache2handler SAPI and using ErrorDocument,
which points to an PHP script. If this ErrorDocument is triggered, then
apache child crashes.

It must be connected with the bug #33987
and as ironic it is, PHP 4.4.1 Changelog claims, that #33987  is fixed.
Bug #33987 is actually reported against PHP5.1 and not against 4.4.0.
PHP 4.4.0 works fine with ErrorDocuments.

-

I looked into the apache2handler source
(sapi/apache2handler/sapi_apache2.c) and after debugging it was clear,
that crash happens on line (538):

   if (parent_req  strcmp(parent_req-handler, PHP_MAGIC_TYPE) 
strcmp(parent_req-handler, PHP_SOURCE_MAGIC_TYPE) 
strcmp(parent_req-handler, PHP_SCRIPT)) {

If changed to this:

   if (parent_req  parent_req-handler  strcmp(parent_req-handler,
PHP_MAGIC_TYPE)  strcmp(parent_req-handler, PHP_SOURCE_MAGIC_TYPE) 
strcmp(parent_req-handler, PHP_SCRIPT)) {

then everything's fine and works.

The correct extra check is present in 5.1.0 (but for some odd reason
not in 4.4.1 and 5.0.5).

Reproduce code:
---
.htaccess
-
ErrorDocument 404 /error.php?status=404

/error.php
-
die( File Not Found! );


Expected result:

File Not Found!

Actual result:
--
Apache2 crashes.





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


#35060 [NEW]: problematic safe_mode restriction in GD library

2005-11-01 Thread moron at industrial dot org
From: moron at industrial dot org
Operating system: FreeBSD (likely all)
PHP version:  4.4.1RC1
PHP Bug Type: Safe Mode/open_basedir
Bug description:  problematic safe_mode restriction in GD library

Description:

A new safe_mode check has been added to PHP's GD library functions that
affects image creation functions.  The changed line is here:

ext/gd/gd.c:1647: if (!fn || fn == empty_string ||
php_check_open_basedir(fn TSRMLS_CC) || (PG(safe_mode) 
!php_checkuid(fn, rb+, CHECKUID_CHECK_FILE_AND_DIR))) {

As of 4.4.1 the following is new:

(PG(safe_mode)  !php_checkuid(fn, rb+, CHECKUID_CHECK_FILE_AND_DIR))

Since this change GD is not able to create new images, presumably due to
the above permissions check failing.


The problem with this code (if I am guessing what php_checkuid does
correctly) is that it seems to make an invalid assumption as to how
ownership works under Unix operating systems. Unless you run PHP as a CGI
(running as the script owner), created files will always be owned by the
generic web user (www, nobody, etc.).  This means that the above check
will fail since the ownership of the created file will not match that of
the parent script.

What should be checked here is the group ownership and file level
permissions since the owner will always be the web user (especially if the
directory structure has been created on the fly). 

As it stands, if you run under safe_mode and with PHP as a module under a
Unix type system, you will always fail the safe_mode check and be unable
to create images with the GD libraries.

Other file system functions appear to be unaffected (i.e.
move_uploaded_file, copy, mkdir, etc.).

Cheers

Reproduce code:
---
?php
// safe_mode is enabled

$img_out=imagecreatetruecolor(200,200);
imagejpeg($img_out,'files/thingy/test.jpg',100);
imagedestroy($img_out);
?




Expected result:

new image created files/thingy/test.jpg

Actual result:
--
Warning: imagejpeg(): Unable to access files/thingy/test.jpg in
/home/moron/www/test.php on line 3

Warning: imagejpeg(): Invalid filename 'files/thingy/test.jpg' in
/home/moron/www/test.php on line 3

Here are the permissions in that directory:

drwxr-xrwx  15 nobody  12345  512 Sep 10  2004 files/thingy/

Here are the permissions on the script:

-rw-r--r--  1 33300  12345122 Nov  1 13:03 test.php

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


#34656 [Com]: open_basedir restriction in effect although paths are set correctly

2005-11-01 Thread troy at riq dot qc dot ca
 ID:   34656
 Comment by:   troy at riq dot qc dot ca
 Reported By:  wolfram at schlich dot org
 Status:   Open
 Bug Type: Safe Mode/open_basedir
 Operating System: Linux 2.2.16 i586
 PHP Version:  4.4.1
 New Comment:

I just backtrack to a old version because 4.4.1 seem buggy with
open_basedir.
../scripts/Connect.php is in the open_basedir but 4.4.1 refuse it.
BTW, the open_basedir is set via apache httpd.conf and have always
work.

PHP Warning:  main(): open_basedir restriction in effect.
File(../scripts/Connect.php) is not within the allowed path(s):
(/webdir/htdocs/site3/) in /webdir/htdocs/site3/something/page.php on
line 2

PHP Warning:  main(../scripts/Connect.php): failed to open stream:
Operation not permitted in /webdir/htdocs/site3/something/page.php on
line 2

PHP Warning:  main(): Failed opening '../scripts/Connect.php' for
inclusion (include_path='.:/webapp/lib/php') in
/webdir/htdocs/site3/something/page.php on line 2

Hope it will be fix soon!
Have a nice day.


Previous Comments:


[2005-11-01 15:01:35] wolfram at schlich dot org

Just tried with the freshly released 4.4.1, without luck:
--8--
Warning: fopen(): open_basedir restriction in effect.
File(/tmp/foo.bar) is not within the allowed path(s):
(/home/sites/site81/:/tmp/:/usr/share/pear/) in
/home/sites/site81/web/fopen.php on line 3

Warning: fopen(/tmp/foo.bar): failed to open stream: Operation not
permitted in /home/sites/site81/web/fopen.php on line 3
--8--

--8--[ access.conf ]--8--
DirectoryMatch /home/sites/site81/
php_admin_value open_basedir
/home/sites/site81/:/tmp/:/usr/share/pear/
/DirectoryMatch
--8--



[2005-10-05 01:00:09] php-bugs at lists dot php dot net

No feedback was provided for this bug for over a week, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to Open.



[2005-09-27 19:53:27] [EMAIL PROTECTED]

Give feedback when you have some..



[2005-09-27 19:47:49] wolfram at schlich dot org

thanks! will do.



[2005-09-27 19:27:01] [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

Something related to open_basedir and the paths was just fixed. Give it
an hour or two.




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

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


#35059 [Opn-Fbk]: Problems with PHP 4.4.1 and mod_rewrite

2005-11-01 Thread sniper
 ID:   35059
 Updated by:   [EMAIL PROTECTED]
 Reported By:  free4cd at yahoo dot de
-Status:   Open
+Status:   Feedback
 Bug Type: Apache2 related
 Operating System: SuSE 9.3
 PHP Version:  4.4.1RC1
 New Comment:

Please try using this CVS snapshot:

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




Previous Comments:


[2005-11-01 21:57:35] free4cd at yahoo dot de

Description:

After updating two different webservers to PHP 4.4.1 I get always a
blank page with PHP 4.4.1 and mod_rewrite if you click on a link.
Start page load normal but on every additional page you see nothing. No
error in error log. Happens with vBulletin and mod_rewrite and Joomla
1.0.3 with mod_rewrite enabled and apache 2.0.55. With PHP 4.4.0 and
same settings in php.ini there are no problems. Only PHP version has
changed

Reproduce code:
---
Install Joomla 1.0.3 and use mod_rewrite and apache 2.0.x. Enable SEO
in Joomla.

Settings in .htaccess:

RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*) index.php







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


#35054 [Opn-Fbk]: Heavy Random Lag During foreach loop

2005-11-01 Thread sniper
 ID:   35054
 Updated by:   [EMAIL PROTECTED]
 Reported By:  starcitsura at shaw dot ca
-Status:   Open
+Status:   Feedback
 Bug Type: Performance problem
 Operating System: Linux
 PHP Version:  4.4.1RC1
 New Comment:

Are you sure it's not Apache or Mysql lagging? Where do you get the
idea it's automatically PHP's fault? Can you provide a script which can
be run in CLI and which does NOT use mysql?
(and which is actually complete script and not just useless piece of a
huge one)



Previous Comments:


[2005-11-01 18:41:16] starcitsura at shaw dot ca

Description:

For some reason there is random lag when echoing the results.
Now I say random lightly because there seems to be a tendency for
certain items to be more likely to slow down then others, for instance
at one point I ran the script about 10 times, and item six in the list
always slowed down.

The lag seemed to occur inside the part that echoed each image and
link, at that time the lag would only occur on the image for the down
button which makes even less sense.
I used a micro time function that would echo the time since the last
one was called. The lag seemed to occur during the html portion of the
code., which doesn’t make much sense to me.

What is causing this lag? I have also written the code so that it
echo’s the html instead of the way its done now, there was no effect on
the lag

I wouldn't be worried about it if it was only like 15 milliseconds
difference, but the lag varies anywhere from 100 ms to 1500ms which is
not acceptable. Some time’s the list is as long as 100 items, in which
case the items with lag are much more common, causing the script to
take as long a 1ms.

I have tested this script on two different servers, the lag occurs on
both.
The main server uses PHP 4.3.11


Reproduce code:
---
foreach($array as $value)
{
  $conID = substr($value, 1);
  switch ($value{0})
  {   #simply choses which mysql query to run, then runs it  }
  list($name,$built) = $data;
  $data = new entity($name);
  $cost = $data-fetchField('Cost'); ?
li?=$name;? (?=($cost-$built);?/?=$cost;?)
a href=?LID=?=$LID;?amp;conID=?=$value{0}.$conID;?amp;shift=up
title=Up
img alt=Up src=../../images/ingame/map/up.gif height=11
width=11 //a
a href=?LID=?=$LID;?amp;conID=?=$value{0}.$conID;?amp;shift=x
title=Cancel
img alt=Cancel src=../../images/ingame/map/x.gif height=11
width=11 //a
/li
?php
}







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


#34871 [Opn-Fbk]: php isapi does not impersonate app. pool user

2005-11-01 Thread sniper
 ID:   34871
 Updated by:   [EMAIL PROTECTED]
 Reported By:  giunta dot gaetano at sea-aeroportimilano dot it
-Status:   Open
+Status:   Feedback
 Bug Type: IIS related
 Operating System: Windows 2003
 PHP Version:  4.4.0
 New Comment:

Are you sure you're doing it the right way (tm) ?



Previous Comments:


[2005-10-14 15:12:38] giunta dot gaetano at sea-aeroportimilano dot it

Quick test:
Anonymous access for IIS set to IUSR_XXX; App Pool user set to
IWAM_XXX; set a .txt file permissions to 'read access only for
IWAM_XXX' and called readfile() on it.



[2005-10-14 15:04:03] [EMAIL PROTECTED]

How did you determine that it isn't impersonating?




[2005-10-14 14:56:53] giunta dot gaetano at sea-aeroportimilano dot it

Description:

I had a very hard time trying to figure out which user will be used to
actually run the php processes on IIS 6+php isapi.

The server is configured in non-IIS5-compliant security mode, and php
runs fine, but it keeps using the windows user account configured for
anonymous website access, instead of the user account set for the
Application Pool connected to the website in question.

All MS docs state that web apps run under the user account/using the
privileges of the account defined for the App. Pool (by default NETWORK
SERVICE).

User comments on the online manual vary wildly: some users seem to have
had success in using the app. pool user, some using the anonymous
connection user.

Docs at
http://www.microsoft.com/technet/prodtechnol/windowsserver2003/technologies/webapp/iis/appisoa.mspx#EGAA
indicate that in order for the web app to exibhit this behaviour, it
has to call the he Win32API RevertToSelf function, of which I sould
finnd no trace in the php source code, except for the FCGI module...

Am I missing something?






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


#34656 [Opn-Fbk]: open_basedir restriction in effect although paths are set correctly

2005-11-01 Thread sniper
 ID:   34656
 Updated by:   [EMAIL PROTECTED]
 Reported By:  wolfram at schlich dot org
-Status:   Open
+Status:   Feedback
 Bug Type: Safe Mode/open_basedir
 Operating System: Linux 2.2.16 i586
 PHP Version:  4.4.1
 New Comment:

Does it work if you set the open_basedir in php.ini ?



Previous Comments:


[2005-11-01 22:19:12] troy at riq dot qc dot ca

I just backtrack to a old version because 4.4.1 seem buggy with
open_basedir.
../scripts/Connect.php is in the open_basedir but 4.4.1 refuse it.
BTW, the open_basedir is set via apache httpd.conf and have always
work.

PHP Warning:  main(): open_basedir restriction in effect.
File(../scripts/Connect.php) is not within the allowed path(s):
(/webdir/htdocs/site3/) in /webdir/htdocs/site3/something/page.php on
line 2

PHP Warning:  main(../scripts/Connect.php): failed to open stream:
Operation not permitted in /webdir/htdocs/site3/something/page.php on
line 2

PHP Warning:  main(): Failed opening '../scripts/Connect.php' for
inclusion (include_path='.:/webapp/lib/php') in
/webdir/htdocs/site3/something/page.php on line 2

Hope it will be fix soon!
Have a nice day.



[2005-11-01 15:01:35] wolfram at schlich dot org

Just tried with the freshly released 4.4.1, without luck:
--8--
Warning: fopen(): open_basedir restriction in effect.
File(/tmp/foo.bar) is not within the allowed path(s):
(/home/sites/site81/:/tmp/:/usr/share/pear/) in
/home/sites/site81/web/fopen.php on line 3

Warning: fopen(/tmp/foo.bar): failed to open stream: Operation not
permitted in /home/sites/site81/web/fopen.php on line 3
--8--

--8--[ access.conf ]--8--
DirectoryMatch /home/sites/site81/
php_admin_value open_basedir
/home/sites/site81/:/tmp/:/usr/share/pear/
/DirectoryMatch
--8--



[2005-09-27 19:27:01] [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

Something related to open_basedir and the paths was just fixed. Give it
an hour or two.




[2005-09-27 12:44:53] wolfram at schlich dot org

Description:

Warning: touch(): open_basedir restriction in effect.
File(/tmp/f5_test) is not within the allowed path(s):
(/home/sites/site15/:/tmp) in /home/sites/site15/web/write_tmp.php on
line 3

Warning: fopen(): open_basedir restriction in effect.
File(/tmp/f5_test) is not within the allowed path(s):
(/home/sites/site15/:/tmp) in /home/sites/site15/web/write_tmp.php on
line 4

Warning: fopen(/tmp/f5_test): failed to open stream: Operation not
permitted in /home/sites/site15/web/write_tmp.php on line 4

Warning: fwrite(): supplied argument is not a valid stream resource in
/home/sites/site15/web/write_tmp.php on line 5

Warning: fclose(): supplied argument is not a valid stream resource in
/home/sites/site15/web/write_tmp.php on line 6

Reproduce code:
---
--8--[ write_tmp.php ]--8--
?php
$tmpfile = /tmp/f5_test;
touch($tmpfile);
$fp = fopen($tmpfile,w);
fwrite($fp, test );
fclose($fp);
?
--8--[ httpd.conf ]--8--
DirectoryMatch /home/sites/site15/
## doesn't work
php_admin_value open_basedir /home/sites/site15/:/tmp
## also doesn't work
# php_admin_value open_basedir /
## works, but is not what's desired
# php_admin_value open_basedir none
/DirectoryMatch
--8--
Also tried to set open_basedir within the VirtualHost, didn'
t work either.

Expected result:

no errors

Actual result:
--
open_basedir errors





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


#35058 [Opn-Bgs]: server abend using spl_autoload and friends

2005-11-01 Thread sniper
 ID:   35058
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Open
+Status:   Bogus
 Bug Type: SPL related
 Operating System: windows 2000
 PHP Version:  5.1.0RC4
 New Comment:

How did you get a @php.net address? Haven't you got ANY idea how to
report? (see: http://bugs.php.net/how-to-report.php)

Try come up with a PERFECT reproducing script or leave this report as
bogus what it now is.




Previous Comments:


[2005-11-01 21:16:21] [EMAIL PROTECTED]

Description:

Similar to http://bugs.php.net/bug.php?id=34216 I am experiencing
intermitent server abends while trying to integrate some of the new
spl_autoload_* functionality in a custom application on apache 1.3.33.
In particular, I am using spl to register a static class method that
implements its own polymorphic autoload behaviours. The custom class
loader is known to work well if called directly from __autoload.

It also appears that all documentation for (and mention of)
spl_autoload_* has disappeared. Is this still intended for 5.1 and/or
are their plans to integrate this into the engine -- where it belongs?






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


#35060 [Com]: problematic safe_mode restriction in GD library

2005-11-01 Thread jerome at blion dot dyndns dot org
 ID:   35060
 Comment by:   jerome at blion dot dyndns dot org
 Reported By:  moron at industrial dot org
 Status:   Open
 Bug Type: Safe Mode/open_basedir
 Operating System: FreeBSD (likely all)
 PHP Version:  4.4.1RC1
 New Comment:

touch('files/thingy/test.jpg');
before imagejpeg worked for me


Previous Comments:


[2005-11-01 22:11:33] moron at industrial dot org

Description:

A new safe_mode check has been added to PHP's GD library functions that
affects image creation functions.  The changed line is here:

ext/gd/gd.c:1647: if (!fn || fn == empty_string ||
php_check_open_basedir(fn TSRMLS_CC) || (PG(safe_mode) 
!php_checkuid(fn, rb+, CHECKUID_CHECK_FILE_AND_DIR))) {

As of 4.4.1 the following is new:

(PG(safe_mode)  !php_checkuid(fn, rb+,
CHECKUID_CHECK_FILE_AND_DIR))

Since this change GD is not able to create new images, presumably due
to the above permissions check failing.


The problem with this code (if I am guessing what php_checkuid does
correctly) is that it seems to make an invalid assumption as to how
ownership works under Unix operating systems. Unless you run PHP as a
CGI (running as the script owner), created files will always be owned
by the generic web user (www, nobody, etc.).  This means that the
above check will fail since the ownership of the created file will not
match that of the parent script.

What should be checked here is the group ownership and file level
permissions since the owner will always be the web user (especially if
the directory structure has been created on the fly). 

As it stands, if you run under safe_mode and with PHP as a module under
a Unix type system, you will always fail the safe_mode check and be
unable to create images with the GD libraries.

Other file system functions appear to be unaffected (i.e.
move_uploaded_file, copy, mkdir, etc.).

Cheers

Reproduce code:
---
?php
// safe_mode is enabled

$img_out=imagecreatetruecolor(200,200);
imagejpeg($img_out,'files/thingy/test.jpg',100);
imagedestroy($img_out);
?




Expected result:

new image created files/thingy/test.jpg

Actual result:
--
Warning: imagejpeg(): Unable to access files/thingy/test.jpg in
/home/moron/www/test.php on line 3

Warning: imagejpeg(): Invalid filename 'files/thingy/test.jpg' in
/home/moron/www/test.php on line 3

Here are the permissions in that directory:

drwxr-xrwx  15 nobody  12345  512 Sep 10  2004 files/thingy/

Here are the permissions on the script:

-rw-r--r--  1 33300  12345122 Nov  1 13:03 test.php





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


#35060 [Opn-Bgs]: problematic safe_mode restriction in GD library

2005-11-01 Thread sniper
 ID:   35060
 Updated by:   [EMAIL PROTECTED]
 Reported By:  moron at industrial dot org
-Status:   Open
+Status:   Bogus
 Bug Type: Safe Mode/open_basedir
 Operating System: FreeBSD (likely all)
 PHP Version:  4.4.1RC1
 New Comment:

and in PHP 5.1 there are even MORE of these checks! =)
(hint: this is not a bug but a feature)




Previous Comments:


[2005-11-01 22:39:24] jerome at blion dot dyndns dot org

touch('files/thingy/test.jpg');
before imagejpeg worked for me



[2005-11-01 22:11:33] moron at industrial dot org

Description:

A new safe_mode check has been added to PHP's GD library functions that
affects image creation functions.  The changed line is here:

ext/gd/gd.c:1647: if (!fn || fn == empty_string ||
php_check_open_basedir(fn TSRMLS_CC) || (PG(safe_mode) 
!php_checkuid(fn, rb+, CHECKUID_CHECK_FILE_AND_DIR))) {

As of 4.4.1 the following is new:

(PG(safe_mode)  !php_checkuid(fn, rb+,
CHECKUID_CHECK_FILE_AND_DIR))

Since this change GD is not able to create new images, presumably due
to the above permissions check failing.


The problem with this code (if I am guessing what php_checkuid does
correctly) is that it seems to make an invalid assumption as to how
ownership works under Unix operating systems. Unless you run PHP as a
CGI (running as the script owner), created files will always be owned
by the generic web user (www, nobody, etc.).  This means that the
above check will fail since the ownership of the created file will not
match that of the parent script.

What should be checked here is the group ownership and file level
permissions since the owner will always be the web user (especially if
the directory structure has been created on the fly). 

As it stands, if you run under safe_mode and with PHP as a module under
a Unix type system, you will always fail the safe_mode check and be
unable to create images with the GD libraries.

Other file system functions appear to be unaffected (i.e.
move_uploaded_file, copy, mkdir, etc.).

Cheers

Reproduce code:
---
?php
// safe_mode is enabled

$img_out=imagecreatetruecolor(200,200);
imagejpeg($img_out,'files/thingy/test.jpg',100);
imagedestroy($img_out);
?




Expected result:

new image created files/thingy/test.jpg

Actual result:
--
Warning: imagejpeg(): Unable to access files/thingy/test.jpg in
/home/moron/www/test.php on line 3

Warning: imagejpeg(): Invalid filename 'files/thingy/test.jpg' in
/home/moron/www/test.php on line 3

Here are the permissions in that directory:

drwxr-xrwx  15 nobody  12345  512 Sep 10  2004 files/thingy/

Here are the permissions on the script:

-rw-r--r--  1 33300  12345122 Nov  1 13:03 test.php





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


#35060 [Bgs]: problematic safe_mode restriction in GD library

2005-11-01 Thread moron at industrial dot org
 ID:   35060
 User updated by:  moron at industrial dot org
 Reported By:  moron at industrial dot org
 Status:   Bogus
 Bug Type: Safe Mode/open_basedir
 Operating System: FreeBSD (likely all)
 PHP Version:  4.4.1RC1
 New Comment:

What is bogus about the bug exactly? If touch() can create the file
then so should imagejpeg() - is that not the entire point of that
function, to create a file?  Nothing in the docus that I could see
state that the file needs to exist previously. 

Also, if this is a feature can you please explain what that feature
is exactly?  It does not seem to adhere to any sane permission scheme I
can think of, at least as far as running PHP as a module under UNIX
style operating systems go.

If this feature will not be going away, any chance of getting the
imagejpeg docs updated to note that the new requirement is that the
file in question already exists before it can be written to?

Cheers


Previous Comments:


[2005-11-01 22:51:14] [EMAIL PROTECTED]

and in PHP 5.1 there are even MORE of these checks! =)
(hint: this is not a bug but a feature)





[2005-11-01 22:39:24] jerome at blion dot dyndns dot org

touch('files/thingy/test.jpg');
before imagejpeg worked for me



[2005-11-01 22:11:33] moron at industrial dot org

Description:

A new safe_mode check has been added to PHP's GD library functions that
affects image creation functions.  The changed line is here:

ext/gd/gd.c:1647: if (!fn || fn == empty_string ||
php_check_open_basedir(fn TSRMLS_CC) || (PG(safe_mode) 
!php_checkuid(fn, rb+, CHECKUID_CHECK_FILE_AND_DIR))) {

As of 4.4.1 the following is new:

(PG(safe_mode)  !php_checkuid(fn, rb+,
CHECKUID_CHECK_FILE_AND_DIR))

Since this change GD is not able to create new images, presumably due
to the above permissions check failing.


The problem with this code (if I am guessing what php_checkuid does
correctly) is that it seems to make an invalid assumption as to how
ownership works under Unix operating systems. Unless you run PHP as a
CGI (running as the script owner), created files will always be owned
by the generic web user (www, nobody, etc.).  This means that the
above check will fail since the ownership of the created file will not
match that of the parent script.

What should be checked here is the group ownership and file level
permissions since the owner will always be the web user (especially if
the directory structure has been created on the fly). 

As it stands, if you run under safe_mode and with PHP as a module under
a Unix type system, you will always fail the safe_mode check and be
unable to create images with the GD libraries.

Other file system functions appear to be unaffected (i.e.
move_uploaded_file, copy, mkdir, etc.).

Cheers

Reproduce code:
---
?php
// safe_mode is enabled

$img_out=imagecreatetruecolor(200,200);
imagejpeg($img_out,'files/thingy/test.jpg',100);
imagedestroy($img_out);
?




Expected result:

new image created files/thingy/test.jpg

Actual result:
--
Warning: imagejpeg(): Unable to access files/thingy/test.jpg in
/home/moron/www/test.php on line 3

Warning: imagejpeg(): Invalid filename 'files/thingy/test.jpg' in
/home/moron/www/test.php on line 3

Here are the permissions in that directory:

drwxr-xrwx  15 nobody  12345  512 Sep 10  2004 files/thingy/

Here are the permissions on the script:

-rw-r--r--  1 33300  12345122 Nov  1 13:03 test.php





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


#35060 [Bgs-Opn]: problematic safe_mode restriction in GD library

2005-11-01 Thread moron at industrial dot org
 ID:   35060
 User updated by:  moron at industrial dot org
 Reported By:  moron at industrial dot org
-Status:   Bogus
+Status:   Open
 Bug Type: Safe Mode/open_basedir
 Operating System: FreeBSD (likely all)
 PHP Version:  4.4.1RC1
 New Comment:

http://ca.php.net/manual/en/function.imagejpeg.php

imagejpeg() creates the JPEG file in filename from the image image.
The image argument is the return from the imagecreatetruecolor()
function.

This definition conflicts with the newly stated requirement that the
file in question already exists.  Either the docs are wrong or the
safe_mode check is broken.


Previous Comments:


[2005-11-01 22:57:10] moron at industrial dot org

What is bogus about the bug exactly? If touch() can create the file
then so should imagejpeg() - is that not the entire point of that
function, to create a file?  Nothing in the docus that I could see
state that the file needs to exist previously. 

Also, if this is a feature can you please explain what that feature
is exactly?  It does not seem to adhere to any sane permission scheme I
can think of, at least as far as running PHP as a module under UNIX
style operating systems go.

If this feature will not be going away, any chance of getting the
imagejpeg docs updated to note that the new requirement is that the
file in question already exists before it can be written to?

Cheers



[2005-11-01 22:51:14] [EMAIL PROTECTED]

and in PHP 5.1 there are even MORE of these checks! =)
(hint: this is not a bug but a feature)





[2005-11-01 22:39:24] jerome at blion dot dyndns dot org

touch('files/thingy/test.jpg');
before imagejpeg worked for me



[2005-11-01 22:11:33] moron at industrial dot org

Description:

A new safe_mode check has been added to PHP's GD library functions that
affects image creation functions.  The changed line is here:

ext/gd/gd.c:1647: if (!fn || fn == empty_string ||
php_check_open_basedir(fn TSRMLS_CC) || (PG(safe_mode) 
!php_checkuid(fn, rb+, CHECKUID_CHECK_FILE_AND_DIR))) {

As of 4.4.1 the following is new:

(PG(safe_mode)  !php_checkuid(fn, rb+,
CHECKUID_CHECK_FILE_AND_DIR))

Since this change GD is not able to create new images, presumably due
to the above permissions check failing.


The problem with this code (if I am guessing what php_checkuid does
correctly) is that it seems to make an invalid assumption as to how
ownership works under Unix operating systems. Unless you run PHP as a
CGI (running as the script owner), created files will always be owned
by the generic web user (www, nobody, etc.).  This means that the
above check will fail since the ownership of the created file will not
match that of the parent script.

What should be checked here is the group ownership and file level
permissions since the owner will always be the web user (especially if
the directory structure has been created on the fly). 

As it stands, if you run under safe_mode and with PHP as a module under
a Unix type system, you will always fail the safe_mode check and be
unable to create images with the GD libraries.

Other file system functions appear to be unaffected (i.e.
move_uploaded_file, copy, mkdir, etc.).

Cheers

Reproduce code:
---
?php
// safe_mode is enabled

$img_out=imagecreatetruecolor(200,200);
imagejpeg($img_out,'files/thingy/test.jpg',100);
imagedestroy($img_out);
?




Expected result:

new image created files/thingy/test.jpg

Actual result:
--
Warning: imagejpeg(): Unable to access files/thingy/test.jpg in
/home/moron/www/test.php on line 3

Warning: imagejpeg(): Invalid filename 'files/thingy/test.jpg' in
/home/moron/www/test.php on line 3

Here are the permissions in that directory:

drwxr-xrwx  15 nobody  12345  512 Sep 10  2004 files/thingy/

Here are the permissions on the script:

-rw-r--r--  1 33300  12345122 Nov  1 13:03 test.php





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


#35059 [Fbk-Opn]: Problems with PHP 4.4.1 and mod_rewrite

2005-11-01 Thread free4cd at yahoo dot de
 ID:   35059
 User updated by:  free4cd at yahoo dot de
 Reported By:  free4cd at yahoo dot de
-Status:   Feedback
+Status:   Open
 Bug Type: Apache2 related
 Operating System: SuSE 9.3
 PHP Version:  4.4.1RC1
 New Comment:

OK, I try the PHP5 snapshot.
I post the result tomorrow when I've finished the tests if it 
works.


Previous Comments:


[2005-11-01 22:24:00] [EMAIL PROTECTED]

Please try using this CVS snapshot:

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





[2005-11-01 21:57:35] free4cd at yahoo dot de

Description:

After updating two different webservers to PHP 4.4.1 I get always a
blank page with PHP 4.4.1 and mod_rewrite if you click on a link.
Start page load normal but on every additional page you see nothing. No
error in error log. Happens with vBulletin and mod_rewrite and Joomla
1.0.3 with mod_rewrite enabled and apache 2.0.55. With PHP 4.4.0 and
same settings in php.ini there are no problems. Only PHP version has
changed

Reproduce code:
---
Install Joomla 1.0.3 and use mod_rewrite and apache 2.0.x. Enable SEO
in Joomla.

Settings in .htaccess:

RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*) index.php







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


#35054 [Fbk-Csd]: Heavy Random Lag During foreach loop

2005-11-01 Thread starcitsura at shaw dot ca
 ID:   35054
 User updated by:  starcitsura at shaw dot ca
 Reported By:  starcitsura at shaw dot ca
-Status:   Feedback
+Status:   Closed
 Bug Type: Performance problem
 Operating System: Linux
 PHP Version:  4.4.1RC1
 New Comment:

nevermind then


Previous Comments:


[2005-11-01 22:26:17] [EMAIL PROTECTED]

Are you sure it's not Apache or Mysql lagging? Where do you get the
idea it's automatically PHP's fault? Can you provide a script which can
be run in CLI and which does NOT use mysql?
(and which is actually complete script and not just useless piece of a
huge one)




[2005-11-01 18:41:16] starcitsura at shaw dot ca

Description:

For some reason there is random lag when echoing the results.
Now I say random lightly because there seems to be a tendency for
certain items to be more likely to slow down then others, for instance
at one point I ran the script about 10 times, and item six in the list
always slowed down.

The lag seemed to occur inside the part that echoed each image and
link, at that time the lag would only occur on the image for the down
button which makes even less sense.
I used a micro time function that would echo the time since the last
one was called. The lag seemed to occur during the html portion of the
code., which doesn’t make much sense to me.

What is causing this lag? I have also written the code so that it
echo’s the html instead of the way its done now, there was no effect on
the lag

I wouldn't be worried about it if it was only like 15 milliseconds
difference, but the lag varies anywhere from 100 ms to 1500ms which is
not acceptable. Some time’s the list is as long as 100 items, in which
case the items with lag are much more common, causing the script to
take as long a 1ms.

I have tested this script on two different servers, the lag occurs on
both.
The main server uses PHP 4.3.11


Reproduce code:
---
foreach($array as $value)
{
  $conID = substr($value, 1);
  switch ($value{0})
  {   #simply choses which mysql query to run, then runs it  }
  list($name,$built) = $data;
  $data = new entity($name);
  $cost = $data-fetchField('Cost'); ?
li?=$name;? (?=($cost-$built);?/?=$cost;?)
a href=?LID=?=$LID;?amp;conID=?=$value{0}.$conID;?amp;shift=up
title=Up
img alt=Up src=../../images/ingame/map/up.gif height=11
width=11 //a
a href=?LID=?=$LID;?amp;conID=?=$value{0}.$conID;?amp;shift=x
title=Cancel
img alt=Cancel src=../../images/ingame/map/x.gif height=11
width=11 //a
/li
?php
}







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


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

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

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


Previous Comments:


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

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



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

See also bug #32600 (rpath set wrong too)



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

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

RCPT TO:[EMAIL PROTECTED] 

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

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




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

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

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

Full file:

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

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



[2004-04-17 19:14:01] jordi at jcanals dot net

Description:

In windows, and using an SMTP server, when you try to send a mail using
the mail function the SMTP transaction will fail if you include
recipient names.

When including any recipient header in the following format (wich
follows the RFC 2822), the mail function does not handle it properly:

To: User Name [EMAIL PROTECTED]
Cc: Other User [EMAIL PROTECTED]
Bcc: Third User [EMAIL PROTECTED]

Loking at the SMTP transaction, the PHP mail layer sends this RCPT
commands wich do not folow the SMTP standard stated on RFC 2821:

RCPT TO:User Name [EMAIL PROTECTED]
RCPT TO:Other User [EMAIL PROTECTED]
RCPT TO:Third User [EMAIL PROTECTED]

Fails always with this environments:
Tested on Windows XP, Apache 2.0.49, PHP 4.3.6 (Also in 4.3.4)
Tested also on Windows 2000, IIS, PHP 4.3.6

Tested Using SMTP servers on Linux with Exim and Sendmail.
Tested also using the default Windows 2000 SMTP server.

Reproduce code:
---
// SAMPLE 1:

$to_recipient = User Name [EMAIL PROTECTED];
$header = Cc: Other User [EMAIL PROTECTED]\r\n;
$header .= Bcc: Third User [EMAIL PROTECTED]\r\n;
mail($to_recipient, $subject, $body, $header);

// FAILS with SMTP errors for all three recipients.

SAMPLE 2:
$to_recipient = [EMAIL PROTECTED];
$header = To: User Name [EMAIL PROTECTED]\r\n;
$header .= Cc: Other User [EMAIL PROTECTED]\r\n;
$header .= Bcc: Third User [EMAIL PROTECTED]\r\n;
mail($to_recipient, $subject, $body, $header);

FAILS on with SMTP error on the three recipients passed on the $header
field.

Expected result:

Expected that the mail layer exctracts only the mail address from
recipients to send the SMTP commands:

As seen on the RFC's 2821 and 2822, when sending a mail with the
recipient headers formed like above, it is expected the mail layer to
extract ONLY the email address to send the RCPT commands, and pass the
headers without any change in the DATA command during the SMTP
transaction. Example of the  correct SMTP transaction for the above
headers:

RCPT TO:[EMAIL PROTECTED]
RCPT TO:[EMAIL PROTECTED]
RCPT TO:[EMAIL PROTECTED]

DATA

To: User Name [EMAIL PROTECTED]
Cc: Other User [EMAIL PROTECTED]
Bcc: Third User [EMAIL PROTECTED]


Actual result:
--
You get that error for all recipients with the recipient name:

Warning: mail(): SMTP server response: 501 SomeOne Name
[EMAIL PROTECTED]: @ or . expected after SomeOne in
mail.class.php on line 333

This error is produced when the mail layer is sending a wrong formed
RCPT TO: command in the SMTP transaction.





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


#34746 [Com]: SOAP_PERSISTENCE_SESSION no longer works

2005-11-01 Thread mir at miras dot org
 ID:   34746
 Comment by:   mir at miras dot org
 Reported By:  brent at jeneral dot com
 Status:   No Feedback
 Bug Type: SOAP related
 Operating System: Freebsd 5.4
 PHP Version:  5.0.5
 New Comment:

Hi,

I would like this to be reopened because I have the same problems:

loke:~/Projekter/php/soap/basic$ dpkg -s php5.0
Package: php5.0
Status: install ok installed
Priority: optional
Section: interpreters
Installed-Size: 20
Maintainer: Piotr Roszatycki [EMAIL PROTECTED]
Architecture: all
Version: 5.0.5-0.8
Provides: php5

Server:
?php
session_start();
class HelloServer {
private $count;

function __construct() {
$this-count = 0;
}

function sayhello() {
$this-count++;
return $this-count;
}
}
$options = array(uri = http://test-uri/;);
$server = new SoapServer(NULL, $options);
$server-setClass(HelloServer);
$server-setPersistence(SOAP_PERSISTENCE_SESSION);
$server-handle();
?

Client:
?php

function format($s)
{
$s = str_replace(, \n, $s);
return pre . htmlspecialchars($s) . /pre;
}

print htmlheadtitleSession Test/title/headbody;
$option = array(
location =
http://localhost/~mir/soap/php5/session/soapSessionServer.php;,
uri = http://test-uri/;,
trace = 1);
$client = new SoapClient(NULL, $option);
$arg = array();
try
{
$response = $client-__soapCall(sayhello, $arg);
print pResponse:br$response/p;
}
catch(SoapFault $sf)
{
print pResponse:br . $sf-getMessage() . /p\n;
}

print format($client-__getLastRequestHeaders()) . \n;
print format($client-__getLastRequest()) . \n;
print format($client-__getLastResponseHeaders()) . \n;
print format($client-__getLastResponse()) . \n;
print /body/html;
?

Output - first time rune:
HTTP/1.1 200 OK
Date: Tue, 01 Nov 2005 23:05:25 GMT
Server: Apache/2.0.55 (Debian) mod_python/3.1.3 Python/2.3.5
PHP/5.0.5-Debian-0.8 mod_perl/2.0.1 Perl/v5.8.7
X-Powered-By: PHP/5.0.5-Debian-0.8
Set-Cookie: PHPSESSID=c6d215abd0930d3c48bb82dc9645b8ea; path=/
Expires: Thu, 19 Nov 1981 08:52:00 GMT
Cache-Control: no-store, no-cache, must-revalidate, post-check=0,
pre-check=0
Pragma: no-cache
Content-Length: 505
Keep-Alive: timeout=15, max=100
Connection: Keep-Alive
Content-Type: text/xml; charset=utf-8

Output - second time:
HTTP/1.1 200 OK
Date: Tue, 01 Nov 2005 23:23:09 GMT
Server: Apache/2.0.55 (Debian) mod_python/3.1.3 Python/2.3.5
PHP/5.0.5-Debian-0.8 mod_perl/2.0.1 Perl/v5.8.7
X-Powered-By: PHP/5.0.5-Debian-0.8
Set-Cookie: PHPSESSID=94b0f37c8de99c263a74b3f657d12f3a; path=/
Expires: Thu, 19 Nov 1981 08:52:00 GMT
Cache-Control: no-store, no-cache, must-revalidate, post-check=0,
pre-check=0
Pragma: no-cache
Content-Length: 505
Keep-Alive: timeout=15, max=100
Connection: Keep-Alive
Content-Type: text/xml; charset=utf-8

As can be seen the session id changes for every call. Looking for the
cookie on the client shows the problem - the cookie is never stored on
the client so succeding invocations does not send any session id back
which causes the server to think this is a new session.


Previous Comments:


[2005-10-21 01:00:05] php-bugs at lists dot php dot net

No feedback was provided for this bug for over a week, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to Open.



[2005-10-17 21:06:56] justin at eckhouse dot com

I seem to be having the same issue, both with 5.0.5 and 5.1RC1 when
using SOAP_PERSISTENCE_SESSION.

- Justin



[2005-10-13 10:55:07] [EMAIL PROTECTED]

I don't get how changing this line can help to fix the problem.
Imagine that you've build PHP with SOAP enabled and after that you've
additionally built session module.
Both of them would be available, but SOAP wouldn't know about session.

In FreeBSD all extensions are dinamically loaded, so the 
persistence session support cannot work anymore.
This is the weirdest way to build PHP I've seen, which creates a lot of
troubles for users and doesn't solve any problems.
I've already saw a lot of confusion from FreeBSD users that install PHP
and discover that none of the modules (that are usually enabled by
default) are there.



[2005-10-13 08:19:15] ale at FreeBSD dot org

I think the problem is this: in soap.c you changed all the following
rows

#if HAVE_PHP_SESSION

with

#if HAVE_PHP_SESSION  !defined(COMPILE_DL_SESSION)

In FreeBSD all extensions are dinamically loaded, so the persistence
session support cannot work anymore. Moreover, in FreeBSD, 

#34746 [NoF-Opn]: SOAP_PERSISTENCE_SESSION no longer works

2005-11-01 Thread brent at jeneral dot com
 ID:   34746
 User updated by:  brent at jeneral dot com
 Reported By:  brent at jeneral dot com
-Status:   No Feedback
+Status:   Open
 Bug Type: SOAP related
 Operating System: Freebsd 5.4
 PHP Version:  5.0.5
 New Comment:

The workaround is to change all

#if HAVE_PHP_SESSION  !defined(COMPILE_DL_SESSION)

back to 

#if HAVE_PHP_SESSION

in soap.c

I agree that this is an ongoing issue.  It seems as though there's an
unresolved discussion as to who owns the problem.


Previous Comments:


[2005-11-02 00:59:11] mir at miras dot org

Hi,

I would like this to be reopened because I have the same problems:

loke:~/Projekter/php/soap/basic$ dpkg -s php5.0
Package: php5.0
Status: install ok installed
Priority: optional
Section: interpreters
Installed-Size: 20
Maintainer: Piotr Roszatycki [EMAIL PROTECTED]
Architecture: all
Version: 5.0.5-0.8
Provides: php5

Server:
?php
session_start();
class HelloServer {
private $count;

function __construct() {
$this-count = 0;
}

function sayhello() {
$this-count++;
return $this-count;
}
}
$options = array(uri = http://test-uri/;);
$server = new SoapServer(NULL, $options);
$server-setClass(HelloServer);
$server-setPersistence(SOAP_PERSISTENCE_SESSION);
$server-handle();
?

Client:
?php

function format($s)
{
$s = str_replace(, \n, $s);
return pre . htmlspecialchars($s) . /pre;
}

print htmlheadtitleSession Test/title/headbody;
$option = array(
location =
http://localhost/~mir/soap/php5/session/soapSessionServer.php;,
uri = http://test-uri/;,
trace = 1);
$client = new SoapClient(NULL, $option);
$arg = array();
try
{
$response = $client-__soapCall(sayhello, $arg);
print pResponse:br$response/p;
}
catch(SoapFault $sf)
{
print pResponse:br . $sf-getMessage() . /p\n;
}

print format($client-__getLastRequestHeaders()) . \n;
print format($client-__getLastRequest()) . \n;
print format($client-__getLastResponseHeaders()) . \n;
print format($client-__getLastResponse()) . \n;
print /body/html;
?

Output - first time rune:
HTTP/1.1 200 OK
Date: Tue, 01 Nov 2005 23:05:25 GMT
Server: Apache/2.0.55 (Debian) mod_python/3.1.3 Python/2.3.5
PHP/5.0.5-Debian-0.8 mod_perl/2.0.1 Perl/v5.8.7
X-Powered-By: PHP/5.0.5-Debian-0.8
Set-Cookie: PHPSESSID=c6d215abd0930d3c48bb82dc9645b8ea; path=/
Expires: Thu, 19 Nov 1981 08:52:00 GMT
Cache-Control: no-store, no-cache, must-revalidate, post-check=0,
pre-check=0
Pragma: no-cache
Content-Length: 505
Keep-Alive: timeout=15, max=100
Connection: Keep-Alive
Content-Type: text/xml; charset=utf-8

Output - second time:
HTTP/1.1 200 OK
Date: Tue, 01 Nov 2005 23:23:09 GMT
Server: Apache/2.0.55 (Debian) mod_python/3.1.3 Python/2.3.5
PHP/5.0.5-Debian-0.8 mod_perl/2.0.1 Perl/v5.8.7
X-Powered-By: PHP/5.0.5-Debian-0.8
Set-Cookie: PHPSESSID=94b0f37c8de99c263a74b3f657d12f3a; path=/
Expires: Thu, 19 Nov 1981 08:52:00 GMT
Cache-Control: no-store, no-cache, must-revalidate, post-check=0,
pre-check=0
Pragma: no-cache
Content-Length: 505
Keep-Alive: timeout=15, max=100
Connection: Keep-Alive
Content-Type: text/xml; charset=utf-8

As can be seen the session id changes for every call. Looking for the
cookie on the client shows the problem - the cookie is never stored on
the client so succeding invocations does not send any session id back
which causes the server to think this is a new session.



[2005-10-21 01:00:05] php-bugs at lists dot php dot net

No feedback was provided for this bug for over a week, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to Open.



[2005-10-17 21:06:56] justin at eckhouse dot com

I seem to be having the same issue, both with 5.0.5 and 5.1RC1 when
using SOAP_PERSISTENCE_SESSION.

- Justin



[2005-10-13 10:55:07] [EMAIL PROTECTED]

I don't get how changing this line can help to fix the problem.
Imagine that you've build PHP with SOAP enabled and after that you've
additionally built session module.
Both of them would be available, but SOAP wouldn't know about session.

In FreeBSD all extensions are dinamically loaded, so the 
persistence session support cannot work anymore.
This is the weirdest way to build PHP I've seen, which creates a lot of
troubles for users and doesn't solve any problems.
I've already saw a lot of confusion from FreeBSD users that install PHP
and discover that none of the modules (that are usually enabled by
default) are there.


#34746 [Com]: SOAP_PERSISTENCE_SESSION no longer works

2005-11-01 Thread mir at miras dot org
 ID:   34746
 Comment by:   mir at miras dot org
 Reported By:  brent at jeneral dot com
 Status:   Open
 Bug Type: SOAP related
 Operating System: Freebsd 5.4
 PHP Version:  5.0.5
 New Comment:

Now it gets spookie.

I downgraded from the php5-5.0.5 from the maintainer of php5 on Debian
to the official php5-5.0.5 in Sid and in this version it works. Checked
soap.c in the official version with my former version and the showed to
be identical!


Previous Comments:


[2005-11-02 01:17:36] brent at jeneral dot com

The workaround is to change all

#if HAVE_PHP_SESSION  !defined(COMPILE_DL_SESSION)

back to 

#if HAVE_PHP_SESSION

in soap.c

I agree that this is an ongoing issue.  It seems as though there's an
unresolved discussion as to who owns the problem.



[2005-11-02 00:59:11] mir at miras dot org

Hi,

I would like this to be reopened because I have the same problems:

loke:~/Projekter/php/soap/basic$ dpkg -s php5.0
Package: php5.0
Status: install ok installed
Priority: optional
Section: interpreters
Installed-Size: 20
Maintainer: Piotr Roszatycki [EMAIL PROTECTED]
Architecture: all
Version: 5.0.5-0.8
Provides: php5

Server:
?php
session_start();
class HelloServer {
private $count;

function __construct() {
$this-count = 0;
}

function sayhello() {
$this-count++;
return $this-count;
}
}
$options = array(uri = http://test-uri/;);
$server = new SoapServer(NULL, $options);
$server-setClass(HelloServer);
$server-setPersistence(SOAP_PERSISTENCE_SESSION);
$server-handle();
?

Client:
?php

function format($s)
{
$s = str_replace(, \n, $s);
return pre . htmlspecialchars($s) . /pre;
}

print htmlheadtitleSession Test/title/headbody;
$option = array(
location =
http://localhost/~mir/soap/php5/session/soapSessionServer.php;,
uri = http://test-uri/;,
trace = 1);
$client = new SoapClient(NULL, $option);
$arg = array();
try
{
$response = $client-__soapCall(sayhello, $arg);
print pResponse:br$response/p;
}
catch(SoapFault $sf)
{
print pResponse:br . $sf-getMessage() . /p\n;
}

print format($client-__getLastRequestHeaders()) . \n;
print format($client-__getLastRequest()) . \n;
print format($client-__getLastResponseHeaders()) . \n;
print format($client-__getLastResponse()) . \n;
print /body/html;
?

Output - first time rune:
HTTP/1.1 200 OK
Date: Tue, 01 Nov 2005 23:05:25 GMT
Server: Apache/2.0.55 (Debian) mod_python/3.1.3 Python/2.3.5
PHP/5.0.5-Debian-0.8 mod_perl/2.0.1 Perl/v5.8.7
X-Powered-By: PHP/5.0.5-Debian-0.8
Set-Cookie: PHPSESSID=c6d215abd0930d3c48bb82dc9645b8ea; path=/
Expires: Thu, 19 Nov 1981 08:52:00 GMT
Cache-Control: no-store, no-cache, must-revalidate, post-check=0,
pre-check=0
Pragma: no-cache
Content-Length: 505
Keep-Alive: timeout=15, max=100
Connection: Keep-Alive
Content-Type: text/xml; charset=utf-8

Output - second time:
HTTP/1.1 200 OK
Date: Tue, 01 Nov 2005 23:23:09 GMT
Server: Apache/2.0.55 (Debian) mod_python/3.1.3 Python/2.3.5
PHP/5.0.5-Debian-0.8 mod_perl/2.0.1 Perl/v5.8.7
X-Powered-By: PHP/5.0.5-Debian-0.8
Set-Cookie: PHPSESSID=94b0f37c8de99c263a74b3f657d12f3a; path=/
Expires: Thu, 19 Nov 1981 08:52:00 GMT
Cache-Control: no-store, no-cache, must-revalidate, post-check=0,
pre-check=0
Pragma: no-cache
Content-Length: 505
Keep-Alive: timeout=15, max=100
Connection: Keep-Alive
Content-Type: text/xml; charset=utf-8

As can be seen the session id changes for every call. Looking for the
cookie on the client shows the problem - the cookie is never stored on
the client so succeding invocations does not send any session id back
which causes the server to think this is a new session.



[2005-10-21 01:00:05] php-bugs at lists dot php dot net

No feedback was provided for this bug for over a week, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to Open.



[2005-10-17 21:06:56] justin at eckhouse dot com

I seem to be having the same issue, both with 5.0.5 and 5.1RC1 when
using SOAP_PERSISTENCE_SESSION.

- Justin



[2005-10-13 10:55:07] [EMAIL PROTECTED]

I don't get how changing this line can help to fix the problem.
Imagine that you've build PHP with SOAP enabled and after that you've
additionally built session module.
Both of them would be available, but SOAP wouldn't know about session.

In FreeBSD all extensions are dinamically loaded, so the 

#35041 [Bgs-Csd]: if (strpos(123,1)===true) doesn't work. if (strpos(123,1)!==false) does

2005-11-01 Thread john dot clements at publicinfo dot net
 ID:   35041
 User updated by:  john dot clements at publicinfo dot net
 Reported By:  john dot clements at publicinfo dot net
-Status:   Bogus
+Status:   Closed
 Bug Type: Strings related
 Operating System: Windows xp pro sp2
 PHP Version:  5CVS-2005-10-31 (snap)
 New Comment:

I reported this as a documentation issue using the web form found from
the manual. The response was to report it as a bug. So I did. Now I
will go back and report it again as a documentation issue and submit my
own documentation comment.


Previous Comments:


[2005-11-01 07:36:31] [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

strpos doesn\'t return true on success but the position  



[2005-11-01 00:12:28] john dot clements at publicinfo dot net

Description:

This is a problem with === true and !== true whether used with strpos
or with array_search and presumably with other functions.

This also fails under PHP 4.3.10 on FreeBSD 4.8-STABLE,
but that is a hosted server and I can't upgrade it to test.

I have done further testing and found that 
checking for === false or !== false is OK:
=== false works when statement is true
=== false works when statement is false
=== true doesn't work when statement is true
=== true works when statement is false
!== true  doesn't work when statement is true
!== true  works when statement is false
!== false works when statement is true
!== false works when statement is false
Pls get in touch if you would like the code to show that. 


Reproduce code:
---
?php

if (strpos(hey,h) === true) print 1. worked \n;
else print 1. didn't work\n;
if (strpos(hey,h) !== false) print 2. worked \n;
else print 2. didn't work\n;
?


Expected result:

1. worked
2. worked


Actual result:
--
1. didn't work
2. worked






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


#35048 [Opn]: parse_ini_file() influenced by putenv() in special situation

2005-11-01 Thread liber at iproom dot com
 ID:   35048
 User updated by:  liber at iproom dot com
 Reported By:  liber at iproom dot com
 Status:   Open
 Bug Type: *General Issues
 Operating System: Windows XP
 PHP Version:  5CVS-2005-11-01 (snap)
 New Comment:

The Apache2 crash with follow messages:

Application Failure Apache.exe 2.0.53.0 in
php5ts.dll 5.1.0.0 at offset 000ab595


Previous Comments:


[2005-11-01 17:27:37] liber at iproom dot com

I have try the latest PHP version (5.1.0 RC 5-dev)
The situation is the same.

Only if I disable the putenv command to stop put 'TZ' data,
then everything is normal.

When I re-enable to put 'TZ' by putenv, the error occur again.

And I forgot to say, additional, the apache2 will crash with this error
sometimes.



[2005-11-01 14:27:35] [EMAIL PROTECTED]

Please try using this CVS snapshot:

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





[2005-11-01 13:39:37] liber at iproom dot com

Description:

First, var_dump the result read by parse_ini_file is:
array (
  'dbHost' = 'localhost',
  'dbUser' = 'mmcwebapp',
  'dbPassword' = '',
  'dbName' = 'faraday',
)

but i don't know why, everytime after
the command: putenv(TZ=);

the result will change as follow:

array (
  'dbHost' = 'localhost',
  'dbUser' = 'mmcwebapp',
  'dbPassword' = '',
  'faradayc8XC9-2' = 'faraday',
)

I can't not figure out where problem is,
then I use Zend Studio and add a watch like this

var_export(parse_ini_file(DBX_CONFIG_FILE),1)

the DBX_CONFIG_FILE is defined as like as c:\a.ini

then I saw the changing in debug mode(step by step).






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


#35061 [NEW]: imagegif,png,ipg.second parameter can not be set ''(null)

2005-11-01 Thread surfchen at gmail dot com
From: surfchen at gmail dot com
Operating system: Redhat AS
PHP version:  4.4.0
PHP Bug Type: GD related
Bug description:  imagegif,png,ipg.second parameter can not be set ''(null)

Description:

1)the imagegif,imagejpg,imagepng can not be used with tow parameters which
the 2nd parameter is ''(null).but if give the function more than 2
parameters,it works.
2)imagegif can give 4 parameters while the document just says it just have
tow parameters.



Reproduce code:
---
?php//incorrect.1)
$img=imagecreatefromgif('2.gif');
header(Content-type:image/gif);
imagegif($img,'');
?
?php//correct(with 4 parameters).2)
$img=imagecreatefromgif('2.gif');
header(Content-type:image/gif);
imagegif($img,'',55,22);
?

Expected result:

1) should ouput correct.
2) should ouput a error because that it have 4 parameters

Actual result:
--
1)output a incorrect image
2)ouput correctly

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


#35040 [Com]: slowness and timeouts when using php-4.4.1

2005-11-01 Thread mc at nuxit dot net
 ID:   35040
 Comment by:   mc at nuxit dot net
 Reported By:  sbailey at mileone dot com
 Status:   Feedback
 Bug Type: Performance problem
 Operating System: FreeBSD 5.3
 PHP Version:  4.4.1RC1
 New Comment:

I have the same problem. SquirrelMail is taking a lot of CPU since
4.4.1 and timeouts.

I've got a backtrace with gdb when it timeouts :

#0  zend_hash_copy (target=0x8531ee4, source=0x0,
pCopyConstructor=0x81dd370 zval_add_ref, tmp=0x5da5b718, size=4)
at /src/php-4.4.1/Zend/zend_hash.c:799
#1  0x081dd4c5 in _zval_copy_ctor (zvalue=0x87b8a6c) at
/src/php-4.4.1/Zend/zend_variables.c:125
#2  0x081ed959 in execute (op_array=0x846b4f8) at
/src/php-4.4.1/Zend/zend_execute.c:1899
#3  0x081ece16 in execute (op_array=0x8489538) at
/src/php-4.4.1/Zend/zend_execute.c:1719
#4  0x081ece16 in execute (op_array=0x84656ec) at
/src/php-4.4.1/Zend/zend_execute.c:1719


Previous Comments:


[2005-11-01 17:46:58] gabe at mudbugmedia dot com

I haven't managed to discover if this is a SquirrelMail bug or 
a PHP bug, but the change from 4.4.0 to 4.4.1 definitely 
causes the break down.

A bug report with a work around is available at SquirrelMail's 
sourceforge page. http://sourceforge.net/tracker/index.php?
func=detailaid=1344216group_id=311atid=100311 .  The work 
around is to turn on server side sorting (in your config.php 
file) to prevent the effected function from being called.



[2005-10-31 21:35:21] vmlinuz386 at yahoo dot com dot ar

I have the same problem, but running on apache-1.3.34 (Linux), with the
php-4.4.1, i am back to php-4.4.0 and this fixes.
Here is the phpinfo() http://www.vmlinuz.com.ar/phpinfo.php

Squirrelmail is 1.4.5, can browse all pages, but the problem  appear
when open a message.

Another problem is that httpd takes many more seconds to stop with
4.4.1, not with 4.4.0.



[2005-10-31 21:13:21] [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.




[2005-10-31 20:53:39] sbailey at mileone dot com

Description:

Installed a fresh install of php-4.4.1 and the only compile options
were --with-apxs2 and I am running apache 2.0.55 on FreeBSD 5.3 and
when I run SquirrelMail version 1.4.5 httpd takes alot of system
resources and is really slow.  I can provide more info if nessary.

Thanks






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


#35062 [NEW]: socket_read() produces warninigs on non blocking sockets

2005-11-01 Thread dima at dimych dot sumy dot ua
From: dima at dimych dot sumy dot ua
Operating system: FreeBSD 4.9-STABLE #0
PHP version:  4.4.1RC1
PHP Bug Type: Sockets related
Bug description:  socket_read() produces warninigs on non blocking sockets

Description:

Use of socket_read() on non blocking sockets produces warinigs like:
socket_read() unable to read from socket [35]: Resource temporarily
unavailable

I`m storing all php errors in log file /var/log/php.log.
This warning causes overflow of /var partition because socket_read()
called to wait icmp message. 


Reproduce code:
---
$socket = socket_create(AF_INET, SOCK_RAW, 1);
socket_connect($socket, $host, null);
$startTime = microtime_float(true);
socket_send($socket, $data, strLen($data), 0);
socket_set_nonblock($socket);
while((microtime_float() - $startTime)  0.5) {
  $mt = microtime_float();
  if (socket_read($socket, 255)) {
 break;
  }
}
socket_close($socket);


Expected result:

no warnings in php.log

Actual result:
--
I`m receive huge count of warinigs in my php.log file like this:
socket_read() unable to read from socket [35]: Resource temporarily
unavailable


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