#34354 [NEW]: parse_ini_file interprets "null" as empty string

2005-09-02 Thread php dot net at sharpdreams dot com
From: php dot net at sharpdreams dot com
Operating system: Win32
PHP version:  5CVS-2005-09-03 (snap)
PHP Bug Type: Filesystem function related
Bug description:  parse_ini_file interprets "null" as empty string

Description:

The documentation is unclear on this aspect so I am presuming this is a
bug:

Keys in INI files set to null (no quotes) are parsed as empty string ""
instead of a true null.

If this is intended behavior then it should be documented as such.

Reproduce code:
---
-- test.ini --
[foo]
bar = null

-- test.php --
var_dump( parse_ini_file( "test.ini" ) );

Expected result:

array(1) {
  ["foo"]=>
  NULL
}

Actual result:
--
array(1) {
  ["foo"]=>
  string(0) ""
}

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


#32301 [Opn->Fbk]: PHP hangs during decompression

2005-09-02 Thread sniper
 ID:   32301
 Updated by:   [EMAIL PROTECTED]
 Reported By:  ralph at cs dot cf dot ac dot uk
-Status:   Open
+Status:   Feedback
 Bug Type: Zlib Related
 Operating System: MacOS X 10.3.x
 PHP Version:  5CVS-2005-03-30
 New Comment:

What I meant with better script is a standalone and short script which
has nothing to do with PEAR.


Previous Comments:


[2005-09-02 10:39:42] ralph at cs dot cf dot ac dot uk

New test:

sudo pear install Image_Barcode



[2005-09-02 10:36:18] [EMAIL PROTECTED]

So you need to come up with a better test script..




[2005-09-02 10:08:09] ralph at cs dot cf dot ac dot uk

Hmm. there is something odd going on here.

This snapshot does solve the problem on MacOS X 10.4.2 for 
the test case reported.

However, the original source of the problem was when 
installing stuff with PEAR, and that STILL does NOT work.

E.g.  sudo pear install Image_Barcode
downloading Image_Barcode-1.0.4.tgz ...
Starting to download Image_Barcode-1.0.4.tgz (13,150 bytes)
.done: 13,150 bytes

Hangs, processor running flat out, until aborted with CTRL-
C.

Before, after a long discussion with the PEAR folks, they 
produced the test case reported here to show it was not a 
PEAR bug.

Unfortunately, the fix so far seems to fix the test case, 
but not the real problem to be addressed!



[2005-09-02 08:53:26] [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

And don't invent your own PHP versions. The version string in the bug
reports must start with a NUMBER..




[2005-03-30 15:45:59] ralph at cs dot cf dot ac dot uk

Have tried this with 
php5-200503301230

Bug is still present.



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

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


#34336 [Opn]: ext/gd: imagerotate destroys transparency information

2005-09-02 Thread [EMAIL PROTECTED]
 ID:   34336
 User updated by:  [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
 Status:   Open
 Bug Type: Feature/Change Request
 Operating System: *
 PHP Version:  5CVS, 4CVS (2005-08-31)
 Assigned To:  pajoye
 New Comment:

JFY, a new fourth parameter "ignore_transparent" was already added to
imagerotate in PHP 5.1 - see http://php.net/imagerotate


Previous Comments:


[2005-09-03 00:06:30] [EMAIL PROTECTED]

Well, it works for PHP5, but what to do with PHP4?

Why it is impossible to change the behavior to keep transparency by
default?

Why change transparent to black while rotating in PHP4? 

It still seems like a bug to me.

Why this doesn't work either?

...
$sprTransparent = imagecolortransparent($spr);

//sprite rotation
$rotate = 15;
$spr = imagerotate($spr, $rotate, $sprTransparent); 
$sprTransparent = imagecolortransparent($spr, $sprTransparent);
...



[2005-09-02 10:10:10] [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


Try the newly added 4th argument:

imagerotate($rsr, $angle, $bg_color, $keeptransparency);

However, note that this is interpolated colors in the destination
images (rotated), meaning that if the original image has some
antialiased artifacts with the bgd color, you will notice them in the
rotated image (in your case, a white border), not much can be done
against that.

--Pierre





[2005-09-01 21:41:26] [EMAIL PROTECTED]

Description:

Imagerotate doesn't preserve transparency information.
Next image was used in example below:
http://img24.imageshack.us/img24/228/spritepaw8alpha2os.png


Reproduce code:
---


Expected result:

Rotated image with transparent background.

Actual result:
--
Rotated image with black background.





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


#34336 [Fbk->Opn]: ext/gd: imagerotate destroys transparency information

2005-09-02 Thread [EMAIL PROTECTED]
 ID:   34336
 User updated by:  [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Feedback
+Status:   Open
 Bug Type: Feature/Change Request
 Operating System: *
 PHP Version:  5CVS, 4CVS (2005-08-31)
 Assigned To:  pajoye
 New Comment:

Well, it works for PHP5, but what to do with PHP4?

Why it is impossible to change the behavior to keep transparency by
default?

Why change transparent to black while rotating in PHP4? 

It still seems like a bug to me.

Why this doesn't work either?

...
$sprTransparent = imagecolortransparent($spr);

//sprite rotation
$rotate = 15;
$spr = imagerotate($spr, $rotate, $sprTransparent); 
$sprTransparent = imagecolortransparent($spr, $sprTransparent);
...


Previous Comments:


[2005-09-02 10:10:10] [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


Try the newly added 4th argument:

imagerotate($rsr, $angle, $bg_color, $keeptransparency);

However, note that this is interpolated colors in the destination
images (rotated), meaning that if the original image has some
antialiased artifacts with the bgd color, you will notice them in the
rotated image (in your case, a white border), not much can be done
against that.

--Pierre





[2005-09-01 21:41:26] [EMAIL PROTECTED]

Description:

Imagerotate doesn't preserve transparency information.
Next image was used in example below:
http://img24.imageshack.us/img24/228/spritepaw8alpha2os.png


Reproduce code:
---


Expected result:

Rotated image with transparent background.

Actual result:
--
Rotated image with black background.





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


#34353 [Opn->Fbk]: func_get_arg(s) leak

2005-09-02 Thread sniper
 ID:   34353
 Updated by:   [EMAIL PROTECTED]
 Reported By:  devik at cdi dot cz
-Status:   Open
+Status:   Feedback
 Bug Type: Scripting Engine problem
 Operating System: Linux
 PHP Version:  5.1.0RC1
 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

I can not reproduce with latest CVS checkout of PHP_5_1 branch.



Previous Comments:


[2005-09-02 22:55:29] devik at cdi dot cz

Description:

There is missing INIT_PZVAL(return_value);
at end of zif_func_get_arg thus it is leaking
data.

Reproduce code:
---



Expected result:

2/copy/build/php-5.1.0RC1/Zend/zend_vm_execute.h(167) :  Freeing
0x08466324 (16 bytes), script=tst.php
=== Total 1 memory leaks detected ===

Actual result:
--
2





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


#34307 [Ctl->Csd]: OnUpdateStringUnempty INI options can be set empty

2005-09-02 Thread sniper
 ID:   34307
 Updated by:   [EMAIL PROTECTED]
 Reported By:  michael at zend dot com
-Status:   Critical
+Status:   Closed
 Bug Type: Scripting Engine problem
 Operating System: *
 PHP Version:  5CVS, 4CVS, 6CVS (2005-09-02
 New Comment:

Fixed properly now. (thanks to Andrei)



Previous Comments:


[2005-09-02 16:14:18] [EMAIL PROTECTED]

My patch didn't work properly. The whole ini thing is a mess.




[2005-09-01 16:44:26] [EMAIL PROTECTED]

Fixed in HEAD and PHP_5_1 branches.



[2005-09-01 09:54:21] michael at zend dot com

Yes, this patch fixes it.



[2005-08-31 10:31:30] [EMAIL PROTECTED]

This patch fixes the ini mess:

  http://www.php.net/~jani/patches/ini_fix.patch

Can you try it out and confirm that it fixes it?




[2005-08-31 08:33:28] [EMAIL PROTECTED]

This is interesting since you shouldn't even be able to set that option
as empty..




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

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


#34339 [WFx]: linking probleme oci8 in 32bit with oracle 64bit...

2005-09-02 Thread info at ch2o dot info
 ID:   34339
 User updated by:  info at ch2o dot info
 Reported By:  info at ch2o dot info
 Status:   Wont fix
 Bug Type: OCI8 related
 Operating System: HP-UX
-PHP Version:  4.4.0
+PHP Version:  4.4.0 and 5.0.4
 New Comment:

have tested backport to php4.4 and 5.0 of oci8/config.m4 from PHP 5.1
with add of the PHP_CHECK_64BIT in acinclude.m4
and work fine on hp-ux 11.11 with oracle 9i 64Bit...

checking for Oracle (OCI8) support using ORACLE_HOME installation...
yes
checking Oracle Install Directory... /usr/local/oracle/
checking for long int... yes
checking size of long int... 4
checking checking if we're at 64-bit platform... no
checking OCI8 libraries dir... lib32
checking Oracle version... 9.0
checking for OCIEnvNlsCreate in -lclntsh... yes
checking for OCINlsCharSetNameToId in -lclntsh... yes
checking for OCILobIsTemporary in -lclntsh... yes
checking for OCICollAssign in -lclntsh... yes

in fact the 64Bit test work fine, is my fault have focalized on the
size of the long int of 4 byte for 64Bit... but is reverse test : if
not sized 4 byte is 64Bit! ...

have tested also with instant client... and work fine also...


Previous Comments:


[2005-09-02 20:07:19] info at ch2o dot info

i can't test the 64bit completely the 64Bit compile mode on hp-ux, in
case i must compile all depandancy of php in 64Bit mode and is very
long operation for my little time i have...but i can test the cli
compile with hp-ux compiler but with only the included module... i
while try it if i have some time in the near future...

but in 32bit compile mode on hp-ux 64Bit, with the autodetecting of the
good Oracle lib dir (lib or lib32), with the oci8/config.m4 (version
1.51) provided by php5.1 (a good solution) they dont work because the
macro PHP_CHECK_64BIT detect that php are compiled in 64Bit not in
32Bit... 
because "long int" are 4 bit on hp-ux 11.11 on 64Bit hardware in 32bit
compiled binary... 
but the compiler bloc the setting of variable with value lager than
32Bit...is why i sugest to modify the detection scheme of the 64Bit on
hp-ux with the example have maked before...

or if php4 and php5 are not compiled in 64bit environement, to modify
oci8/config.m4 like that have sugested (in first) for php 4.4 and 5.0
(the two have the same problem!) for privileging 32bit version of
oracle library...

i'm testing backport to 4.4 and 5.0 of this modification...
with modification of the detecting method of the 64BIT mode...



[2005-09-02 08:34:32] [EMAIL PROTECTED]

If the way it checks 64bit platform doesn't work for you @ HP-UX and
you're able to test it - please provide a patch as we don't have HP-UX
anywhere.



[2005-09-02 07:19:36] [EMAIL PROTECTED]

We start supporting 64bit at PHP 5.1.





[2005-09-02 02:18:13] info at ch2o dot info

i think that the modification 1.51 (51 branch) of config.m4 of oci8 (in
relation i think with bug #29402) while be ok...
 
but i'm not sure that the PHP_CHECK_64BIT (in acinclude.m4) is ok!
because "int" and "long int" are 4 bytes in 32bit mode...on hp-ux 64bit
(HP-UX 11.11 on PA RISC)...(tested with gcc 32Bit and HP-UX cc in 32bit
and 64Bit!)

the only way i found to detect 64bit on hp-ux is to test macro __LP64__
(on pa risc, beceause on itanium i thnik is differente..)...



[2005-09-02 01:30:08] info at ch2o dot info

Description:

all oracle 64Bit version are delivered with 32bit and 64bit client...

on hp-ux with Oracle 9i 64Bit, the $ORACLE_HOME/lib have 64bit client
library and $ORACLE_HOME/lib32 the 32Bit version...
(seem to be the same on AIX, and i think is the same probleme on other
64bit plateforme with oracle 64bit)

with Oracle 8i 64bit the $ORACLE_HOME/lin containt 32bit version and
$ORACLE_HOME/lib64 the 64Bit version...

when you whant compile php + oci8 in 32bit with oracle 8i 64bit have no
probleme...
but with 9i they dont work beceause the 32bit client lib are in
$ORACLE_HOME/lib32 not in $ORACLE_HOME/lib...

with the detection schema used in oci8 ext, they cannot compile php +
oci8 in 32bit with oracle 9i 64Bit...

why i whant to compile php in 32Bit with Oracle 64Bit...
on hp-ux there no precompiled version for 64Bit of all opensource
needed for compiling php and all the nessary for use php...

i think the probleme is the same with the 10g...


Reproduce code:
---
na

Expected result:

na

Actual result:
--
have modified the config.m4 of the oci8...

have replace $OCI8_DIR/lib with $OCI8_LIBDIR...
and have added at the start of AC_OCI8_VERSION:
OCI8_LIBDIR=$OCI8_DIR/lib

and have added :
  elif test -f $OCI8_DIR/lib32/libcln

#30931 [Com]: is_writable() and is_readable() return false when access is permitted via ACL

2005-09-02 Thread 1 at 234 dot cx
 ID:   30931
 Comment by:   1 at 234 dot cx
 Reported By:  bugzilla-php at bwurst dot org
 Status:   No Feedback
 Bug Type: Filesystem function related
 Operating System: gentoo linux (kernel 2.6)
 PHP Version:  5.0.2
 New Comment:

I was just wondering if anyone can review the patch which has been
posted here.  This seems to be a well defined bug with a patch that
solves the problem, is there any reason not to check it in?

If there *is* a reason not to check the patch in, I am sure one of us
will work on improving it.  Before we can do this, though, we need a
clue what issues people see with the patch as it stands.


Previous Comments:


[2005-08-26 03:03:50] matthew at acintrix dot net

I too am expierencing this bug on Fedora Core 4 with PHP 
5.0.4.



[2005-08-08 18:18:11] ka at pacific dot net

Same bug found here in 5.04 on Fedora Core 4 with modphp
Symptom: modphp cannot write to files even if they are `chmod 777`, if
there is an acl for apache on the file.



[2005-06-15 23:51:26] 1 at 234 dot cx

I don't know if this is useful to anyone, but this seems to be a
regression of bug #14923, which was fixed back in 2002.

I have just experienced the bug on Fedora 4.  I tried JR's patch, and
that solves the problem for me.

Thanks,
Pete



[2005-06-12 16:16:35] jr at terragate dot net

I've written a patch to address this issue.

It uses POSIX's access function to determine file 
permissions.

I tested this patch on Mac OS 10.4.1, Windows XP SP2 and 
FreeBSD 5.2.1.

I am not sure if this patch also works for Win 9x (maybe 
R_OK, W_OK etc. are not defined there) and other non POSIX 
conformant OSes. Probably some more #ifndefs are required.

http://jr.terragate.net/access.diff



[2005-05-12 21:34:01] nickls at apple dot com

This also effects OS X Tiger ACLs.
Why was this changed from access() on PHP 4.3.X?



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

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


#34353 [NEW]: func_get_arg(s) leak

2005-09-02 Thread devik at cdi dot cz
From: devik at cdi dot cz
Operating system: Linux
PHP version:  5.1.0RC1
PHP Bug Type: Scripting Engine problem
Bug description:  func_get_arg(s) leak

Description:

There is missing INIT_PZVAL(return_value);
at end of zif_func_get_arg thus it is leaking
data.

Reproduce code:
---



Expected result:

2/copy/build/php-5.1.0RC1/Zend/zend_vm_execute.h(167) :  Freeing
0x08466324 (16 bytes), script=tst.php
=== Total 1 memory leaks detected ===

Actual result:
--
2

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


#34345 [Opn->WFx]: Extend ArrayObject::setFlags functionality

2005-09-02 Thread helly
 ID:   34345
 Updated by:   [EMAIL PROTECTED]
 Reported By:  stochnagara at hotmail dot com
-Status:   Open
+Status:   Wont fix
 Bug Type: Feature/Change Request
 Operating System: *
 PHP Version:  5CVS-2005-09-02 (snap)
 Assigned To:  helly
 New Comment:

Reading it again i must say that it is not possible to fill your gap.


Previous Comments:


[2005-09-02 22:00:31] [EMAIL PROTECTED]

The documentaion is updated here:
http://php.net/~helly



[2005-09-02 13:25:09] stochnagara at hotmail dot com

Description:

ArrayObject has a method called setFlags. This method is still not
documented (set bug #34101). Anyway, I found out what is its possible
purpose - if the passed parameter is an even number then ArrayObject's
internal array values are printed in var_dump and if the passed
parameter is an odd number then object properties of the class which
extends ArrayObject are show. (See also bug #33799).

But I suggest setFlags fills another gap: set possible values to be 0,
1 or 2. 0 and 1 keep old functionality and 2 allows var_dump to print
both internal array values and properties of the class.

Reproduce code:
---
var = 'override';
$this['internal'] = 'base';
}
}

$foo = new dummy();
for ($i = 0; $i < 3; $i++) {
$foo->setFlags ($i);
var_dump($foo);
}


Expected result:

object(dummy)#1 (1) {
  ["internal"]=>
  string(4) "base"
}
object(dummy)#1 (1) {
  ["var"]=>
  string(8) "override"
}
object(dummy)#1 (2) {
  ["internal"]=>
  string(4) "base",
  ["var"]=>
  string(8) "override"
}


Actual result:
--
object(dummy)#1 (1) {
  ["internal"]=>
  string(4) "base"
}
object(dummy)#1 (1) {
  ["var"]=>
  string(8) "override"
}
object(dummy)#1 (1) {
  ["internal"]=>
  string(4) "base"
}






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


#34346 [Opn->Bgs]: Missing symbols when using SAPI

2005-09-02 Thread sniper
 ID:   34346
 Updated by:   [EMAIL PROTECTED]
 Reported By:  emiel at emielmols dot info
-Status:   Open
+Status:   Bogus
 Bug Type: Apache2 related
 Operating System: Linux 2.6
 PHP Version:  5.1.0RC1
 New Comment:

They're exported just fine. Rebogusing.



Previous Comments:


[2005-09-02 18:47:59] emiel at emielmols dot info

Furthermore, if you check the symbol defenition (in Zend/zend_vm.h),
you'll see that this specific symbol should be exported in both php 5.0
and 5.1. Perhaps someone can enlighten me on de differences in the
exporting of symbols between SAPI/CLI version and/or PHP5.0/PHP5.1, so
I can do some debugging myself too.



[2005-09-02 18:42:44] emiel at emielmols dot info

Not true, i've reinstalled the build- and headerfiles. It does work
with CLI build of the same version.



[2005-09-02 17:57:57] [EMAIL PROTECTED]

It just means that your installed php extension build environment is
out-dated and not compatible with 5.1..




[2005-09-02 16:54:58] emiel at emielmols dot info

Description:

When using php extensions with php in sapi mode, the extensions fail to
load because of 'missing symbols'. While PHP5.0 works perfectly fine,
about 10 different 5.1 versions i've tried don't. I've only tested this
with the runkit extension, but I'm quite certain it's a php bug. The CLI
version of php5.1 doesn't give any error either.

Steps used to compile the extension:
http://public.emielmols.info/runkit.log
Debug log: http://public.emielmols.info/runkit_c.log

PHPInfo: http://public.emielmols.info/phpinfo.php

Using apache2.

Reproduce code:
---

(using extension loading in php.ini makes no difference)

Expected result:

Loading of the module

Actual result:
--
Error message (when loading from ini):
PHP Warning:  PHP Startup: Unable to load dynamic library
'/projects/emielmols.info/cms/misc/runkit.so' -
/projects/emielmols.info/cms/misc/runkit.so: undefined symbol:
_zval_ptr_dtor in Unknown on line 0






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


#34345 [Opn]: Extend ArrayObject::setFlags functionality

2005-09-02 Thread helly
 ID:   34345
 Updated by:   [EMAIL PROTECTED]
 Reported By:  stochnagara at hotmail dot com
 Status:   Open
 Bug Type: Feature/Change Request
-Operating System: windows xp
+Operating System: *
 PHP Version:  5CVS-2005-09-02 (snap)
-Assigned To:  
+Assigned To:  helly
 New Comment:

The documentaion is updated here:
http://php.net/~helly


Previous Comments:


[2005-09-02 13:25:09] stochnagara at hotmail dot com

Description:

ArrayObject has a method called setFlags. This method is still not
documented (set bug #34101). Anyway, I found out what is its possible
purpose - if the passed parameter is an even number then ArrayObject's
internal array values are printed in var_dump and if the passed
parameter is an odd number then object properties of the class which
extends ArrayObject are show. (See also bug #33799).

But I suggest setFlags fills another gap: set possible values to be 0,
1 or 2. 0 and 1 keep old functionality and 2 allows var_dump to print
both internal array values and properties of the class.

Reproduce code:
---
var = 'override';
$this['internal'] = 'base';
}
}

$foo = new dummy();
for ($i = 0; $i < 3; $i++) {
$foo->setFlags ($i);
var_dump($foo);
}


Expected result:

object(dummy)#1 (1) {
  ["internal"]=>
  string(4) "base"
}
object(dummy)#1 (1) {
  ["var"]=>
  string(8) "override"
}
object(dummy)#1 (2) {
  ["internal"]=>
  string(4) "base",
  ["var"]=>
  string(8) "override"
}


Actual result:
--
object(dummy)#1 (1) {
  ["internal"]=>
  string(4) "base"
}
object(dummy)#1 (1) {
  ["var"]=>
  string(8) "override"
}
object(dummy)#1 (1) {
  ["internal"]=>
  string(4) "base"
}






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


#34349 [Opn->Bgs]: imap_fetchstructure( ) Problem with message/rfc822

2005-09-02 Thread sniper
 ID:   34349
 Updated by:   [EMAIL PROTECTED]
 Reported By:  tony123 at hotmail dot com
-Status:   Open
+Status:   Bogus
 Bug Type: IMAP related
 Operating System: Windows XP PRO SP2
 PHP Version:  5.0.4
 New Comment:

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

Thank you for your interest in PHP.

We have enough reports about this already. (and it's not really our
problem, blame c-client)



Previous Comments:


[2005-09-02 18:35:58] tony123 at hotmail dot com

Description:

Hi I found people in many webboard talked about some problem with
message/rfc822 with function

imap_fetcstructure($imap,$id);
imap_fetchbody($imap,$id,"string part number");

And I've experienced with the same problem.

I tried to send an email with outlook express
attach 2 files a.eml, b.eml

with this code...

print_r(imap_fetcstructure($imap,$id));

Result...

..
..
..
 [1] => stdClass Object
(
[type] => 2
[encoding] => 0
[ifsubtype] => 1
[subtype] => RFC822
[ifdescription] => 0
[ifid] => 0
[bytes] => 1768
[ifdisposition] => 0
[ifdparameters] => 0
[ifparameters] => 0
[parameters] => stdClass Object
(
)

[parts] => Array
(
[0] => stdClass Object
(
[type] => 9
[encoding] => 5
[ifsubtype] => 1
[subtype] => UNKNOWN
[ifdescription] => 0
[ifid] => 0
[ifdisposition] => 0
[ifdparameters] => 0
[ifparameters] => 0
[parameters] => stdClass Object
(
)

)

)
--
That's incorrect.

Same problem with the lastest cvs.(5.1.x)

Any idea?

Sorry for my Enlish and typing ?







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


#34186 [Opn->Fbk]: Segment Fault in PHP

2005-09-02 Thread sniper
 ID:   34186
 Updated by:   [EMAIL PROTECTED]
 Reported By:  ljanda at checkstop dot com
-Status:   Open
+Status:   Feedback
 Bug Type: Program Execution
 Operating System: SCO 5.0.5
 PHP Version:  4.4.0
 New Comment:

a) Are you using Zend optimizer or any other zend extension?
b) How did you compile PHP? Did you use some extra CFLAGS?
c) Provide a _SHORT_ reproducing script!



Previous Comments:


[2005-09-02 19:23:56] ljanda at checkstop dot com

Why is the backtrace useless, as that is what the documention says to
provide. Bottom line is that the php  program has a segment violation,
so lets get a fix so everyone can benefit. 

I have provided the script that is causing this, as a short script does
not cause it to fail. 

I can re-create the situation easily, just give me some idea where to
set the break points.



[2005-09-02 17:56:44] [EMAIL PROTECTED]

Can you please ask the questions instead and not add these  totally
useless backtraces here?




[2005-09-02 16:40:12] ljanda at checkstop dot com

# gdb httpd
GNU gdb 5.2
Copyright 2002 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and
you are
welcome to change it and/or distribute copies of it under certain
conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for
details.
This GDB was configured as "i386-pc-sco3.2v5.0.5"...
(gdb) run -X
Starting program: /usr/local/apache133/bin/httpd -X

Program received signal SIGSEGV, Segmentation fault.
0x0806932d in _efree (ptr=warning: Cannot convert floating-point
register value to non-floating-point type.
0x0)
at /u/leroy/php4-STABLE-200508081638/Zend/zend_alloc.c:259
259 REMOVE_POINTER_FROM_LIST(p);
(gdb) bt
#0  0x0806932d in _efree (ptr=warning: Cannot convert floating-point
register value to non-floating-point type.
0x0)
at /u/leroy/php4-STABLE-200508081638/Zend/zend_alloc.c:259
(gdb)



[2005-09-01 23:03:41] [EMAIL PROTECTED]

And what do you mean with optimizer? Are you using your own flags
during compile? Something like -O3 ?




[2005-09-01 23:02:51] [EMAIL PROTECTED]

Are you or are you not going to provide a short reproducing script? If
you're not, let this report rot.




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

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


#34351 [Opn->Bgs]: please reply

2005-09-02 Thread sniper
 ID:   34351
 Updated by:   [EMAIL PROTECTED]
 Reported By:  hitesh_iitg at yahoo dot co dot in
-Status:   Open
+Status:   Bogus
 Bug Type: *Configuration Issues
 Operating System: windows xp
 PHP Version:  4.4.0
 New Comment:

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

Thank you for your interest in PHP.




Previous Comments:


[2005-09-02 21:20:19] hitesh_iitg at yahoo dot co dot in

Description:

Hii I am getting error "Parse error: parse error, unexpected '"',
expecting T_STRING or T_VARIABLE or T_NUM_STRING in C:\Program
Files\Apache Group\Apache2\htdocs\php\prepend.php3 on line 16" when
ever I open Phplib files in web browser like showoff.php3.Line 16 in
prepend.php3 is
"require($_PHPLIB["libdir"] . "db_mysql.inc");  /* Change this to match
your database. */". I have done all the essential changes in
php.ini,local.inc and in prepend.php3. what kind of problem is this.
Please help me to figureout this problem.






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


#34351 [NEW]: please reply

2005-09-02 Thread hitesh_iitg at yahoo dot co dot in
From: hitesh_iitg at yahoo dot co dot in
Operating system: windows xp
PHP version:  4.4.0
PHP Bug Type: *Configuration Issues
Bug description:  please reply

Description:

Hii I am getting error "Parse error: parse error, unexpected '"',
expecting T_STRING or T_VARIABLE or T_NUM_STRING in C:\Program
Files\Apache Group\Apache2\htdocs\php\prepend.php3 on line 16" when ever I
open Phplib files in web browser like showoff.php3.Line 16 in prepend.php3
is
"require($_PHPLIB["libdir"] . "db_mysql.inc");  /* Change this to match
your database. */". I have done all the essential changes in
php.ini,local.inc and in prepend.php3. what kind of problem is this.
Please help me to figureout this problem.


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


#34339 [WFx]: linking probleme oci8 in 32bit with oracle 64bit...

2005-09-02 Thread info at ch2o dot info
 ID:   34339
 User updated by:  info at ch2o dot info
 Reported By:  info at ch2o dot info
 Status:   Wont fix
 Bug Type: OCI8 related
 Operating System: HP-UX
 PHP Version:  4.4.0
 New Comment:

i can't test the 64bit completely the 64Bit compile mode on hp-ux, in
case i must compile all depandancy of php in 64Bit mode and is very
long operation for my little time i have...but i can test the cli
compile with hp-ux compiler but with only the included module... i
while try it if i have some time in the near future...

but in 32bit compile mode on hp-ux 64Bit, with the autodetecting of the
good Oracle lib dir (lib or lib32), with the oci8/config.m4 (version
1.51) provided by php5.1 (a good solution) they dont work because the
macro PHP_CHECK_64BIT detect that php are compiled in 64Bit not in
32Bit... 
because "long int" are 4 bit on hp-ux 11.11 on 64Bit hardware in 32bit
compiled binary... 
but the compiler bloc the setting of variable with value lager than
32Bit...is why i sugest to modify the detection scheme of the 64Bit on
hp-ux with the example have maked before...

or if php4 and php5 are not compiled in 64bit environement, to modify
oci8/config.m4 like that have sugested (in first) for php 4.4 and 5.0
(the two have the same problem!) for privileging 32bit version of
oracle library...

i'm testing backport to 4.4 and 5.0 of this modification...
with modification of the detecting method of the 64BIT mode...


Previous Comments:


[2005-09-02 08:34:32] [EMAIL PROTECTED]

If the way it checks 64bit platform doesn't work for you @ HP-UX and
you're able to test it - please provide a patch as we don't have HP-UX
anywhere.



[2005-09-02 07:19:36] [EMAIL PROTECTED]

We start supporting 64bit at PHP 5.1.





[2005-09-02 02:18:13] info at ch2o dot info

i think that the modification 1.51 (51 branch) of config.m4 of oci8 (in
relation i think with bug #29402) while be ok...
 
but i'm not sure that the PHP_CHECK_64BIT (in acinclude.m4) is ok!
because "int" and "long int" are 4 bytes in 32bit mode...on hp-ux 64bit
(HP-UX 11.11 on PA RISC)...(tested with gcc 32Bit and HP-UX cc in 32bit
and 64Bit!)

the only way i found to detect 64bit on hp-ux is to test macro __LP64__
(on pa risc, beceause on itanium i thnik is differente..)...



[2005-09-02 01:30:08] info at ch2o dot info

Description:

all oracle 64Bit version are delivered with 32bit and 64bit client...

on hp-ux with Oracle 9i 64Bit, the $ORACLE_HOME/lib have 64bit client
library and $ORACLE_HOME/lib32 the 32Bit version...
(seem to be the same on AIX, and i think is the same probleme on other
64bit plateforme with oracle 64bit)

with Oracle 8i 64bit the $ORACLE_HOME/lin containt 32bit version and
$ORACLE_HOME/lib64 the 64Bit version...

when you whant compile php + oci8 in 32bit with oracle 8i 64bit have no
probleme...
but with 9i they dont work beceause the 32bit client lib are in
$ORACLE_HOME/lib32 not in $ORACLE_HOME/lib...

with the detection schema used in oci8 ext, they cannot compile php +
oci8 in 32bit with oracle 9i 64Bit...

why i whant to compile php in 32Bit with Oracle 64Bit...
on hp-ux there no precompiled version for 64Bit of all opensource
needed for compiling php and all the nessary for use php...

i think the probleme is the same with the 10g...


Reproduce code:
---
na

Expected result:

na

Actual result:
--
have modified the config.m4 of the oci8...

have replace $OCI8_DIR/lib with $OCI8_LIBDIR...
and have added at the start of AC_OCI8_VERSION:
OCI8_LIBDIR=$OCI8_DIR/lib

and have added :
  elif test -f $OCI8_DIR/lib32/libclntsh.$SHLIB_SUFFIX_NAME.9.0; then
OCI8_VERSION=9.0
OCI8_LIBDIR=$OCI8_DIR/lib32
before:
  elif test -f $OCI8_LIBDIR/libclntsh.$SHLIB_SUFFIX_NAME.9.0; then

and they worked fine...

but with that, they privilege the 32bit version vs the default version
(the 64bit version with oracle 9i 64Bit)

the seconde posibility is to add --oci8-32bit to force the use of lib32
in place of lib...for use with >=9i 64Bit in 32bit mode...

and --oci8-64bit to force the use of lib64 in place of lib for compile
with Oracle 8i 64bit in 64Bit mode...







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


#34240 [Asn->Csd]: zlib.output_compression=on responsing corrupted data

2005-09-02 Thread iliaa
 ID:   34240
 Updated by:   [EMAIL PROTECTED]
 Reported By:  xuefer at 21cn dot com
-Status:   Assigned
+Status:   Closed
 Bug Type: Zlib Related
 Operating System: *
 PHP Version:  5CVS, 6CVS, 4CVS (2005-08-25)
 Assigned To:  iliaa
 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-09-01 06:23:45] xuefer at 21cn dot com

i'd guess the "start_offset" is to avoid an extra erealloc. 
this bug should only happen when both do_start do_end is true
(do_end=true && start_offset!=0)

 /* {{{ php_do_deflate
@@ -717,7 +718,7 @@
 
if (do_end) {
err = deflate(&ZLIBG(stream), Z_FINISH);
-   buffer[outlen - ZLIBG(stream).avail_out] = '\0';
+   buffer[outlen + start_offset - ZLIBG(stream).avail_out] =
'\0';
}



[2005-09-01 03:00:57] [EMAIL PROTECTED]

I've tried to replicate the bug using given methodology and removing
the \0 line has absolutely no affect (md5 is the same) on the generated
output.



[2005-08-31 14:39:15] xuefer at 21cn dot com

confirmed with ./configure --disable-all --disable-cli --with-zlib
both with cgi and fastcgi

good:
HTTP_ACCEPT_ENCODING=gzip php-cgi test.php |md5sum
826a819e34f7d57597d890de4176c265  -
bad:
HTTP_ACCEPT_ENCODING=gzip php-cgi test.php |md5sum
2e7dc64cd654b82f712b47b790dcbc12  -


(gdb) br 720
Breakpoint 2 at 0x805d6e5: file /home/xuefer/src/php4/ext/zlib/zlib.c,
line 720.
(gdb) r
#0  php_do_deflate (str_length=2, p_buffer=0xb028,
p_buffer_len=0xb02c, do_start=1 '\001', do_end=1 '\001')
at /home/xuefer/src/php4/ext/zlib/zlib.c:720
(gdb) p outlen-zlib_globals.stream.avail_out
$8 = 10
(gdb) p buffer[outlen-zlib_globals.stream.avail_out]
$9 = 50 '2'
(gdb) step
724 *p_buffer = buffer;
(gdb) p buffer[outlen-zlib_globals.stream.avail_out]
$10 = 0 '\0'

the 2 is exactly what i see in httpwatch that get "lost" with the patch
applied

test result by php->lighttpd->httpwatch is at:
ftp://211.92.88.40/pub/phpbug/test.php.response.txt
ftp://211.92.88.40/pub/phpbug/test.php.response-corrupted.txt



[2005-08-30 13:23:51] [EMAIL PROTECTED]

It doesn't make any difference with/without the patch for bug#34191
(so I don't think it really broke anything)

Try with the shortest possible configure line:
# ./configure --disable-all --disable-cli --with-zlib




[2005-08-24 21:14:51] [EMAIL PROTECTED]

Can you replicate in any other SAPI, I don't have fastcgi sapi 
installed anywhere.



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

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


#34186 [Fbk->Opn]: Segment Fault in PHP

2005-09-02 Thread ljanda at checkstop dot com
 ID:   34186
 User updated by:  ljanda at checkstop dot com
 Reported By:  ljanda at checkstop dot com
-Status:   Feedback
+Status:   Open
 Bug Type: Program Execution
 Operating System: SCO 5.0.5
 PHP Version:  4.4.0
 New Comment:

Why is the backtrace useless, as that is what the documention says to
provide. Bottom line is that the php  program has a segment violation,
so lets get a fix so everyone can benefit. 

I have provided the script that is causing this, as a short script does
not cause it to fail. 

I can re-create the situation easily, just give me some idea where to
set the break points.


Previous Comments:


[2005-09-02 17:56:44] [EMAIL PROTECTED]

Can you please ask the questions instead and not add these  totally
useless backtraces here?




[2005-09-02 16:40:12] ljanda at checkstop dot com

# gdb httpd
GNU gdb 5.2
Copyright 2002 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and
you are
welcome to change it and/or distribute copies of it under certain
conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for
details.
This GDB was configured as "i386-pc-sco3.2v5.0.5"...
(gdb) run -X
Starting program: /usr/local/apache133/bin/httpd -X

Program received signal SIGSEGV, Segmentation fault.
0x0806932d in _efree (ptr=warning: Cannot convert floating-point
register value to non-floating-point type.
0x0)
at /u/leroy/php4-STABLE-200508081638/Zend/zend_alloc.c:259
259 REMOVE_POINTER_FROM_LIST(p);
(gdb) bt
#0  0x0806932d in _efree (ptr=warning: Cannot convert floating-point
register value to non-floating-point type.
0x0)
at /u/leroy/php4-STABLE-200508081638/Zend/zend_alloc.c:259
(gdb)



[2005-09-01 23:03:41] [EMAIL PROTECTED]

And what do you mean with optimizer? Are you using your own flags
during compile? Something like -O3 ?




[2005-09-01 23:02:51] [EMAIL PROTECTED]

Are you or are you not going to provide a short reproducing script? If
you're not, let this report rot.




[2005-09-01 22:40:06] ljanda at checkstop dot com

This uses full optimization, correct. I can play with the different
levels.



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

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


#34346 [Bgs->Opn]: Missing symbols when using SAPI

2005-09-02 Thread emiel at emielmols dot info
 ID:   34346
 User updated by:  emiel at emielmols dot info
 Reported By:  emiel at emielmols dot info
-Status:   Bogus
+Status:   Open
 Bug Type: Apache2 related
 Operating System: Linux 2.6
 PHP Version:  5.1.0RC1
 New Comment:

Reopening


Previous Comments:


[2005-09-02 18:47:59] emiel at emielmols dot info

Furthermore, if you check the symbol defenition (in Zend/zend_vm.h),
you'll see that this specific symbol should be exported in both php 5.0
and 5.1. Perhaps someone can enlighten me on de differences in the
exporting of symbols between SAPI/CLI version and/or PHP5.0/PHP5.1, so
I can do some debugging myself too.



[2005-09-02 18:42:44] emiel at emielmols dot info

Not true, i've reinstalled the build- and headerfiles. It does work
with CLI build of the same version.



[2005-09-02 17:57:57] [EMAIL PROTECTED]

It just means that your installed php extension build environment is
out-dated and not compatible with 5.1..




[2005-09-02 16:54:58] emiel at emielmols dot info

Description:

When using php extensions with php in sapi mode, the extensions fail to
load because of 'missing symbols'. While PHP5.0 works perfectly fine,
about 10 different 5.1 versions i've tried don't. I've only tested this
with the runkit extension, but I'm quite certain it's a php bug. The CLI
version of php5.1 doesn't give any error either.

Steps used to compile the extension:
http://public.emielmols.info/runkit.log
Debug log: http://public.emielmols.info/runkit_c.log

PHPInfo: http://public.emielmols.info/phpinfo.php

Using apache2.

Reproduce code:
---

(using extension loading in php.ini makes no difference)

Expected result:

Loading of the module

Actual result:
--
Error message (when loading from ini):
PHP Warning:  PHP Startup: Unable to load dynamic library
'/projects/emielmols.info/cms/misc/runkit.so' -
/projects/emielmols.info/cms/misc/runkit.so: undefined symbol:
_zval_ptr_dtor in Unknown on line 0






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


#34340 [Opn]: imagepstext returns T1Lib Error: Font ID Invalid in this Context

2005-09-02 Thread brian at visionn dot com
 ID:   34340
 User updated by:  brian at visionn dot com
 Reported By:  brian at visionn dot com
 Status:   Open
 Bug Type: GD related
 Operating System: Windows NT
 PHP Version:  5.1.0RC1
 New Comment:

To reproduce, first run the code that work fine. Then introduce an
error, run it. Remove the error, run it. The clean code doesn't work
until a restart of IIS. There is a comment from 2001 in the docs about
this on the imagepstext page...so this might be a T1Lib error that it
can't recover from, and so wouldn't belong as a pure PHP bug(?)


Previous Comments:


[2005-09-02 18:49:14] brian at visionn dot com

apologies, here's a better version of the code with hardcoded values:

$font = imagepsloadfont("C:\\PATH_TO_FONT\\font_file.pfb");
$header_img = imagecreate(320, 20);
$font_color = imagecolorallocate($header_img, 42, 86, 143);
$bg_color = imagecolorallocate($header_img, 255, 255, 255);
imagefill($header_img, 0, 0, $bg_color);
imagepstext($header_img, "TEXT", $font, 18, $font_color,
$bg_color, 0, 16, 0, 0, 0, 16);



[2005-09-02 17:51:35] brian at visionn dot com

That one instance of the error was "reset" by restarting IIS, but any
subsequent errors require a restart of IIS...here's a shorter snippet
of test code:

$font = imagepsloadfont("C:\\PATH_TO_FONT\\font_file.pfb");
$header_img = imagecreate(320, 20);
$font_color = imagecolorallocate($header_img, 42, 86, 143);
$bg_color = imagecolorallocate($header_img, 255, 255, 255);
imagefill($header_img, 0, 0, $bg_color);
imagepstext($header_img, "$text", $font, $fontsize, $font_color,
$bg_color, 0, 16, 0, 0, 0, 16);



[2005-09-02 17:45:00] brian at visionn dot com

The error was fixed by restarting IIS.



[2005-09-02 07:23:28] [EMAIL PROTECTED]

Provide a SHORT reproducing script. You don't need to define any
functions, etc. to test this. (6 lines?)




[2005-09-02 02:23:48] brian at visionn dot com

Description:

When calling imagepstext() on a .pfb file on Windows NT, I get returned
"T1Lib Error: Font ID Invalid in this Context". The font file seems to
load fine with imagepsloadfont() (returns resource identifier), but
when used within imagepstext it doesn't seem to be working properly. Am
I using an invalid font file? Line endings? Something to do with Windows
directory permissions? Like I said, the load works fine to return a
resource...

Reproduce code:
---
http://test.taxloopholes.com/font_test.php

Expected result:

An image tag returned that will show an image dynamically generated
showing the text passed to the function.

Actual result:
--
2 : imagepstext() [function.imagepstext]: T1Lib Error: Font ID Invalid
in this Context





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


#34340 [Opn]: imagepstext returns T1Lib Error: Font ID Invalid in this Context

2005-09-02 Thread brian at visionn dot com
 ID:   34340
 User updated by:  brian at visionn dot com
 Reported By:  brian at visionn dot com
 Status:   Open
 Bug Type: GD related
 Operating System: Windows NT
 PHP Version:  5.1.0RC1
 New Comment:

apologies, here's a better version of the code with hardcoded values:

$font = imagepsloadfont("C:\\PATH_TO_FONT\\font_file.pfb");
$header_img = imagecreate(320, 20);
$font_color = imagecolorallocate($header_img, 42, 86, 143);
$bg_color = imagecolorallocate($header_img, 255, 255, 255);
imagefill($header_img, 0, 0, $bg_color);
imagepstext($header_img, "TEXT", $font, 18, $font_color,
$bg_color, 0, 16, 0, 0, 0, 16);


Previous Comments:


[2005-09-02 17:51:35] brian at visionn dot com

That one instance of the error was "reset" by restarting IIS, but any
subsequent errors require a restart of IIS...here's a shorter snippet
of test code:

$font = imagepsloadfont("C:\\PATH_TO_FONT\\font_file.pfb");
$header_img = imagecreate(320, 20);
$font_color = imagecolorallocate($header_img, 42, 86, 143);
$bg_color = imagecolorallocate($header_img, 255, 255, 255);
imagefill($header_img, 0, 0, $bg_color);
imagepstext($header_img, "$text", $font, $fontsize, $font_color,
$bg_color, 0, 16, 0, 0, 0, 16);



[2005-09-02 17:45:00] brian at visionn dot com

The error was fixed by restarting IIS.



[2005-09-02 07:23:28] [EMAIL PROTECTED]

Provide a SHORT reproducing script. You don't need to define any
functions, etc. to test this. (6 lines?)




[2005-09-02 02:23:48] brian at visionn dot com

Description:

When calling imagepstext() on a .pfb file on Windows NT, I get returned
"T1Lib Error: Font ID Invalid in this Context". The font file seems to
load fine with imagepsloadfont() (returns resource identifier), but
when used within imagepstext it doesn't seem to be working properly. Am
I using an invalid font file? Line endings? Something to do with Windows
directory permissions? Like I said, the load works fine to return a
resource...

Reproduce code:
---
http://test.taxloopholes.com/font_test.php

Expected result:

An image tag returned that will show an image dynamically generated
showing the text passed to the function.

Actual result:
--
2 : imagepstext() [function.imagepstext]: T1Lib Error: Font ID Invalid
in this Context





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


#34346 [Bgs]: Missing symbols when using SAPI

2005-09-02 Thread emiel at emielmols dot info
 ID:   34346
 User updated by:  emiel at emielmols dot info
 Reported By:  emiel at emielmols dot info
 Status:   Bogus
 Bug Type: Apache2 related
 Operating System: Linux 2.6
 PHP Version:  5.1.0RC1
 New Comment:

Furthermore, if you check the symbol defenition (in Zend/zend_vm.h),
you'll see that this specific symbol should be exported in both php 5.0
and 5.1. Perhaps someone can enlighten me on de differences in the
exporting of symbols between SAPI/CLI version and/or PHP5.0/PHP5.1, so
I can do some debugging myself too.


Previous Comments:


[2005-09-02 18:42:44] emiel at emielmols dot info

Not true, i've reinstalled the build- and headerfiles. It does work
with CLI build of the same version.



[2005-09-02 17:57:57] [EMAIL PROTECTED]

It just means that your installed php extension build environment is
out-dated and not compatible with 5.1..




[2005-09-02 16:54:58] emiel at emielmols dot info

Description:

When using php extensions with php in sapi mode, the extensions fail to
load because of 'missing symbols'. While PHP5.0 works perfectly fine,
about 10 different 5.1 versions i've tried don't. I've only tested this
with the runkit extension, but I'm quite certain it's a php bug. The CLI
version of php5.1 doesn't give any error either.

Steps used to compile the extension:
http://public.emielmols.info/runkit.log
Debug log: http://public.emielmols.info/runkit_c.log

PHPInfo: http://public.emielmols.info/phpinfo.php

Using apache2.

Reproduce code:
---

(using extension loading in php.ini makes no difference)

Expected result:

Loading of the module

Actual result:
--
Error message (when loading from ini):
PHP Warning:  PHP Startup: Unable to load dynamic library
'/projects/emielmols.info/cms/misc/runkit.so' -
/projects/emielmols.info/cms/misc/runkit.so: undefined symbol:
_zval_ptr_dtor in Unknown on line 0






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


#34346 [Bgs]: Missing symbols when using SAPI

2005-09-02 Thread emiel at emielmols dot info
 ID:   34346
 User updated by:  emiel at emielmols dot info
 Reported By:  emiel at emielmols dot info
 Status:   Bogus
 Bug Type: Apache2 related
 Operating System: Linux 2.6
 PHP Version:  5.1.0RC1
 New Comment:

Not true, i've reinstalled the build- and headerfiles. It does work
with CLI build of the same version.


Previous Comments:


[2005-09-02 17:57:57] [EMAIL PROTECTED]

It just means that your installed php extension build environment is
out-dated and not compatible with 5.1..




[2005-09-02 16:54:58] emiel at emielmols dot info

Description:

When using php extensions with php in sapi mode, the extensions fail to
load because of 'missing symbols'. While PHP5.0 works perfectly fine,
about 10 different 5.1 versions i've tried don't. I've only tested this
with the runkit extension, but I'm quite certain it's a php bug. The CLI
version of php5.1 doesn't give any error either.

Steps used to compile the extension:
http://public.emielmols.info/runkit.log
Debug log: http://public.emielmols.info/runkit_c.log

PHPInfo: http://public.emielmols.info/phpinfo.php

Using apache2.

Reproduce code:
---

(using extension loading in php.ini makes no difference)

Expected result:

Loading of the module

Actual result:
--
Error message (when loading from ini):
PHP Warning:  PHP Startup: Unable to load dynamic library
'/projects/emielmols.info/cms/misc/runkit.so' -
/projects/emielmols.info/cms/misc/runkit.so: undefined symbol:
_zval_ptr_dtor in Unknown on line 0






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


#34349 [Opn]: imap_fetchstructure( ) Problem with message/rfc822

2005-09-02 Thread tony123 at hotmail dot com
 ID:   34349
 User updated by:  tony123 at hotmail dot com
 Reported By:  tony123 at hotmail dot com
 Status:   Open
-Bug Type: *General Issues
+Bug Type: IMAP related
 Operating System: Windows XP PRO SP2
 PHP Version:  5.0.4
 New Comment:

Oh sorry wrong Category.

Changed :)


Previous Comments:


[2005-09-02 18:35:58] tony123 at hotmail dot com

Description:

Hi I found people in many webboard talked about some problem with
message/rfc822 with function

imap_fetcstructure($imap,$id);
imap_fetchbody($imap,$id,"string part number");

And I've experienced with the same problem.

I tried to send an email with outlook express
attach 2 files a.eml, b.eml

with this code...

print_r(imap_fetcstructure($imap,$id));

Result...

..
..
..
 [1] => stdClass Object
(
[type] => 2
[encoding] => 0
[ifsubtype] => 1
[subtype] => RFC822
[ifdescription] => 0
[ifid] => 0
[bytes] => 1768
[ifdisposition] => 0
[ifdparameters] => 0
[ifparameters] => 0
[parameters] => stdClass Object
(
)

[parts] => Array
(
[0] => stdClass Object
(
[type] => 9
[encoding] => 5
[ifsubtype] => 1
[subtype] => UNKNOWN
[ifdescription] => 0
[ifid] => 0
[ifdisposition] => 0
[ifdparameters] => 0
[ifparameters] => 0
[parameters] => stdClass Object
(
)

)

)
--
That's incorrect.

Same problem with the lastest cvs.(5.1.x)

Any idea?

Sorry for my Enlish and typing ?







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


#34350 [NEW]: no86

2005-09-02 Thread rip86rip at yahoo dot com
From: rip86rip at yahoo dot com
Operating system: Windows95
PHP version:  4.4.0
PHP Bug Type: Unknown/Other Function
Bug description:  no86

Description:

Please visit http://mens-lingerie.vsedveri.info";>Mens
lingerie

Reproduce code:
---
uragan

Expected result:

nothing

Actual result:
--
Mens Lingerie

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


#34349 [NEW]: imap_fetchstructure( ) Problem with message/rfc822

2005-09-02 Thread tony123 at hotmail dot com
From: tony123 at hotmail dot com
Operating system: Windows XP PRO SP2
PHP version:  5.0.4
PHP Bug Type: *General Issues
Bug description:  imap_fetchstructure(  ) Problem with message/rfc822 

Description:

Hi I found people in many webboard talked about some problem with
message/rfc822 with function

imap_fetcstructure($imap,$id);
imap_fetchbody($imap,$id,"string part number");

And I've experienced with the same problem.

I tried to send an email with outlook express
attach 2 files a.eml, b.eml

with this code...

print_r(imap_fetcstructure($imap,$id));

Result...

..
..
..
 [1] => stdClass Object
(
[type] => 2
[encoding] => 0
[ifsubtype] => 1
[subtype] => RFC822
[ifdescription] => 0
[ifid] => 0
[bytes] => 1768
[ifdisposition] => 0
[ifdparameters] => 0
[ifparameters] => 0
[parameters] => stdClass Object
(
)

[parts] => Array
(
[0] => stdClass Object
(
[type] => 9
[encoding] => 5
[ifsubtype] => 1
[subtype] => UNKNOWN
[ifdescription] => 0
[ifid] => 0
[ifdisposition] => 0
[ifdparameters] => 0
[ifparameters] => 0
[parameters] => stdClass Object
(
)

)

)
--
That's incorrect.

Same problem with the lastest cvs.(5.1.x)

Any idea?

Sorry for my Enlish and typing ?



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


#33586 [Com]: Serialization breaks references

2005-09-02 Thread sr at brightlight dot ch
 ID:   33586
 Comment by:   sr at brightlight dot ch
 Reported By:  wmeler at wp dot pl
 Status:   Assigned
 Bug Type: Scripting Engine problem
 Operating System: *
 PHP Version:  5CVS-2005-07-06
 Assigned To:  dmitry
 New Comment:

I experienced a similar problem. An even simpler setup 
already breaks unserialisation (php 5.0.4):

$rec= array('rec' => 'x');
$rec['rec']= &$rec;
echo "print_r:\n".print_r($rec, true);
echo "\nafter unserialisation:\n".print_r(unserialize
(serialize($rec)), true);

The output will be:
print_r:
Array
(
[rec] => Array
 *RECURSION*
)

after unserialisation:
Array
(
[rec] => Array
(
[rec] => 
)

)

With a few more dimensions before the recursion php will 
even crash on OS X 10.4.1

regards


Previous Comments:


[2005-07-22 08:52:12] wmeler at wp dot pl

Do you want simplest to debug example or complicated real world
example?

How about this :



outputs remain the same

you can even substitute 'c' with 'parent' and 'd' with 'child' which
makes it more real but this would change outputs



[2005-07-22 01:03:09] [EMAIL PROTECTED]

In your example you're making a reference to a non-existing variable.
Please come up with something more realistic.




[2005-07-06 12:51:21] wmeler at wp dot pl

I've tried - nothing changed



[2005-07-06 12:17: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-07-06 12:03:59] wmeler at wp dot pl

Description:

After serializing variable with circular reference you get 2 copies of
root variable.
Look at output of reproduce code - var_dump outputs should be the same
but they are not.

for code: 

$c['d2']=&$d;
$d['c2']=&$c;
echo serialize($c);

you get

a:1:{s:2:"d2";a:1:{s:2:"c2";a:1:{s:2:"d2";R:2;}}}

I think that it should be something like

a:1:{s:2:"d2";a:1:{s:2:"c2";R:1;}}


Reproduce code:
---

  &array(1) {
["c2"]=>
&array(2) {
  ["d2"]=>
  &array(1) {
["c2"]=>
&array(2) {
  ["d2"]=>
  *RECURSION*
  ["x"]=>
  string(1) "x"
}
  }
  ["x"]=>
  string(1) "x"
}
  }
  ["x"]=>
  string(1) "x"
}
array(2) {
  ["d2"]=>
  &array(1) {
["c2"]=>
&array(2) {
  ["d2"]=>
  &array(1) {
["c2"]=>
&array(2) {
  ["d2"]=>
  *RECURSION*
  ["x"]=>
  string(1) "x"
}
  }
  ["x"]=>
  string(1) "x"
}
  }
  ["x"]=>
  string(1) "x"
}


Actual result:
--
array(2) {
  ["d2"]=>
  &array(1) {
["c2"]=>
&array(2) {
  ["d2"]=>
  &array(1) {
["c2"]=>
&array(2) {
  ["d2"]=>
  *RECURSION*
  ["x"]=>
  string(1) "x"
}
  }
  ["x"]=>
  string(1) "x"
}
  }
  ["x"]=>
  string(1) "x"
}
array(2) {
  ["d2"]=>
  &array(1) {
["c2"]=>
array(1) {
  ["d2"]=>
  &array(1) {
["c2"]=>
array(1) {
  ["d2"]=>
  *RECURSION*
}
  }
}
  }
  ["x"]=>
  string(1) "x"
}






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


#34346 [Opn->Bgs]: Missing symbols when using SAPI

2005-09-02 Thread sniper
 ID:   34346
 Updated by:   [EMAIL PROTECTED]
 Reported By:  emiel at emielmols dot info
-Status:   Open
+Status:   Bogus
 Bug Type: Apache2 related
 Operating System: Linux 2.6
 PHP Version:  5.1.0RC1
 New Comment:

It just means that your installed php extension build environment is
out-dated and not compatible with 5.1..



Previous Comments:


[2005-09-02 16:54:58] emiel at emielmols dot info

Description:

When using php extensions with php in sapi mode, the extensions fail to
load because of 'missing symbols'. While PHP5.0 works perfectly fine,
about 10 different 5.1 versions i've tried don't. I've only tested this
with the runkit extension, but I'm quite certain it's a php bug. The CLI
version of php5.1 doesn't give any error either.

Steps used to compile the extension:
http://public.emielmols.info/runkit.log
Debug log: http://public.emielmols.info/runkit_c.log

PHPInfo: http://public.emielmols.info/phpinfo.php

Using apache2.

Reproduce code:
---

(using extension loading in php.ini makes no difference)

Expected result:

Loading of the module

Actual result:
--
Error message (when loading from ini):
PHP Warning:  PHP Startup: Unable to load dynamic library
'/projects/emielmols.info/cms/misc/runkit.so' -
/projects/emielmols.info/cms/misc/runkit.so: undefined symbol:
_zval_ptr_dtor in Unknown on line 0






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


#34186 [Opn->Fbk]: Segment Fault in PHP

2005-09-02 Thread sniper
 ID:   34186
 Updated by:   [EMAIL PROTECTED]
 Reported By:  ljanda at checkstop dot com
-Status:   Open
+Status:   Feedback
 Bug Type: Program Execution
 Operating System: SCO 5.0.5
 PHP Version:  4.4.0
 New Comment:

Can you please ask the questions instead and not add these  totally
useless backtraces here?



Previous Comments:


[2005-09-02 16:40:12] ljanda at checkstop dot com

# gdb httpd
GNU gdb 5.2
Copyright 2002 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and
you are
welcome to change it and/or distribute copies of it under certain
conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for
details.
This GDB was configured as "i386-pc-sco3.2v5.0.5"...
(gdb) run -X
Starting program: /usr/local/apache133/bin/httpd -X

Program received signal SIGSEGV, Segmentation fault.
0x0806932d in _efree (ptr=warning: Cannot convert floating-point
register value to non-floating-point type.
0x0)
at /u/leroy/php4-STABLE-200508081638/Zend/zend_alloc.c:259
259 REMOVE_POINTER_FROM_LIST(p);
(gdb) bt
#0  0x0806932d in _efree (ptr=warning: Cannot convert floating-point
register value to non-floating-point type.
0x0)
at /u/leroy/php4-STABLE-200508081638/Zend/zend_alloc.c:259
(gdb)



[2005-09-01 23:03:41] [EMAIL PROTECTED]

And what do you mean with optimizer? Are you using your own flags
during compile? Something like -O3 ?




[2005-09-01 23:02:51] [EMAIL PROTECTED]

Are you or are you not going to provide a short reproducing script? If
you're not, let this report rot.




[2005-09-01 22:40:06] ljanda at checkstop dot com

This uses full optimization, correct. I can play with the different
levels.



[2005-09-01 22:37:06] ljanda at checkstop dot com

Ok, got gdb for SCO and compile it.
Compile PHP --enable-debug, and now it is working.

Something in the optimizer.



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

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


#34340 [Csd->Opn]: imagepstext returns T1Lib Error: Font ID Invalid in this Context

2005-09-02 Thread brian at visionn dot com
 ID:   34340
 User updated by:  brian at visionn dot com
 Reported By:  brian at visionn dot com
-Status:   Closed
+Status:   Open
 Bug Type: GD related
 Operating System: Windows NT
 PHP Version:  5.1.0RC1
 New Comment:

That one instance of the error was "reset" by restarting IIS, but any
subsequent errors require a restart of IIS...here's a shorter snippet
of test code:

$font = imagepsloadfont("C:\\PATH_TO_FONT\\font_file.pfb");
$header_img = imagecreate(320, 20);
$font_color = imagecolorallocate($header_img, 42, 86, 143);
$bg_color = imagecolorallocate($header_img, 255, 255, 255);
imagefill($header_img, 0, 0, $bg_color);
imagepstext($header_img, "$text", $font, $fontsize, $font_color,
$bg_color, 0, 16, 0, 0, 0, 16);


Previous Comments:


[2005-09-02 17:45:00] brian at visionn dot com

The error was fixed by restarting IIS.



[2005-09-02 07:23:28] [EMAIL PROTECTED]

Provide a SHORT reproducing script. You don't need to define any
functions, etc. to test this. (6 lines?)




[2005-09-02 02:23:48] brian at visionn dot com

Description:

When calling imagepstext() on a .pfb file on Windows NT, I get returned
"T1Lib Error: Font ID Invalid in this Context". The font file seems to
load fine with imagepsloadfont() (returns resource identifier), but
when used within imagepstext it doesn't seem to be working properly. Am
I using an invalid font file? Line endings? Something to do with Windows
directory permissions? Like I said, the load works fine to return a
resource...

Reproduce code:
---
http://test.taxloopholes.com/font_test.php

Expected result:

An image tag returned that will show an image dynamically generated
showing the text passed to the function.

Actual result:
--
2 : imagepstext() [function.imagepstext]: T1Lib Error: Font ID Invalid
in this Context





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


#34340 [Fbk->Csd]: imagepstext returns T1Lib Error: Font ID Invalid in this Context

2005-09-02 Thread brian at visionn dot com
 ID:   34340
 User updated by:  brian at visionn dot com
 Reported By:  brian at visionn dot com
-Status:   Feedback
+Status:   Closed
 Bug Type: GD related
 Operating System: Windows NT
 PHP Version:  5.1.0RC1
 New Comment:

The error was fixed by restarting IIS.


Previous Comments:


[2005-09-02 07:23:28] [EMAIL PROTECTED]

Provide a SHORT reproducing script. You don't need to define any
functions, etc. to test this. (6 lines?)




[2005-09-02 02:23:48] brian at visionn dot com

Description:

When calling imagepstext() on a .pfb file on Windows NT, I get returned
"T1Lib Error: Font ID Invalid in this Context". The font file seems to
load fine with imagepsloadfont() (returns resource identifier), but
when used within imagepstext it doesn't seem to be working properly. Am
I using an invalid font file? Line endings? Something to do with Windows
directory permissions? Like I said, the load works fine to return a
resource...

Reproduce code:
---
http://test.taxloopholes.com/font_test.php

Expected result:

An image tag returned that will show an image dynamically generated
showing the text passed to the function.

Actual result:
--
2 : imagepstext() [function.imagepstext]: T1Lib Error: Font ID Invalid
in this Context





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


#34347 [Opn->Asn]: TimzeZones Problem

2005-09-02 Thread derick
 ID:   34347
 Updated by:   [EMAIL PROTECTED]
 Reported By:  thomas at ecommerce dot com
-Status:   Open
+Status:   Assigned
-Bug Type: SPL related
+Bug Type: Date/time related
 Operating System: SuSE Linux
 PHP Version:  5CVS-2005-09-02 (snap)
-Assigned To:  
+Assigned To:  derick
 New Comment:

This has nothing to do with SPL though, also, using a TZ environment
variable is NOT recommended in PHP 5.1 and up.


Previous Comments:


[2005-09-02 16:58:50] thomas at ecommerce dot com

Description:

PHP 5.1 don't know some timezones that was avaible in PHP 5.0. At
first, the setted TZ come from a SPL function ( date() ) and afterwards
saying it doesn't know it.

Ans why will this code bellow set 'UTC' in the ENV var instead of the
before setted CEST?

Reproduce code:
---
http://bugs.php.net/?id=34347&edit=1


#34347 [NEW]: TimzeZones Problem

2005-09-02 Thread thomas at ecommerce dot com
From: thomas at ecommerce dot com
Operating system: SuSE Linux
PHP version:  5CVS-2005-09-02 (snap)
PHP Bug Type: SPL related
Bug description:  TimzeZones Problem

Description:

PHP 5.1 don't know some timezones that was avaible in PHP 5.0. At first,
the setted TZ come from a SPL function ( date() ) and afterwards saying it
doesn't know it.

Ans why will this code bellow set 'UTC' in the ENV var instead of the
before setted CEST?

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


#34346 [NEW]: Missing symbols when using SAPI

2005-09-02 Thread emiel at emielmols dot info
From: emiel at emielmols dot info
Operating system: Linux 2.6
PHP version:  5.1.0RC1
PHP Bug Type: Apache2 related
Bug description:  Missing symbols when using SAPI

Description:

When using php extensions with php in sapi mode, the extensions fail to
load because of 'missing symbols'. While PHP5.0 works perfectly fine,
about 10 different 5.1 versions i've tried don't. I've only tested this
with the runkit extension, but I'm quite certain it's a php bug. The CLI
version of php5.1 doesn't give any error either.

Steps used to compile the extension:
http://public.emielmols.info/runkit.log
Debug log: http://public.emielmols.info/runkit_c.log

PHPInfo: http://public.emielmols.info/phpinfo.php

Using apache2.

Reproduce code:
---

(using extension loading in php.ini makes no difference)

Expected result:

Loading of the module

Actual result:
--
Error message (when loading from ini):
PHP Warning:  PHP Startup: Unable to load dynamic library
'/projects/emielmols.info/cms/misc/runkit.so' -
/projects/emielmols.info/cms/misc/runkit.so: undefined symbol:
_zval_ptr_dtor in Unknown on line 0


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


#34344 [Bgs]: register_shutdown_function() in classes

2005-09-02 Thread thomas at ecommerce dot com
 ID:   34344
 User updated by:  thomas at ecommerce dot com
 Reported By:  thomas at ecommerce dot com
 Status:   Bogus
 Bug Type: SPL related
 Operating System: SuSE Linux
 PHP Version:  5.0.4
 New Comment:

does that mean this code will work in PHP5.0 ( when login function is
public ) and in PHP5.1 this code won't work anymore?


Previous Comments:


[2005-09-02 16:39:49] [EMAIL PROTECTED]

Ah yes, you can't really call any object methods inside a shutdown
function since the objects are destructed before that.



[2005-09-02 16:27:45] thomas at ecommerce dot com

Script start! Init Class.
Class init call!
Registrering shutdown function..
done
Class inited!

Warning: (Registered shutdown functions) Unable to call
TestClass::_log() - function does not exist in Unknown on line 0
--
This is the output with the latest CVS Snap. The problem still exists
and the Error Message is wrong ( function does not exist, but exists )



[2005-09-02 16:15:12] [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-02 12:54:14] thomas at ecommerce dot com

Script start! Init Class.
Class init call!
Registrering shutdown function..
done
Class inited!

Fatal error: Call to private method TestClass::_log() from context ''
in Unknown on line 0
--
is the current result



[2005-09-02 12:53:19] thomas at ecommerce dot com

Updated Expected result part



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

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


#34186 [Fbk->Opn]: Segment Fault in PHP

2005-09-02 Thread ljanda at checkstop dot com
 ID:   34186
 User updated by:  ljanda at checkstop dot com
 Reported By:  ljanda at checkstop dot com
-Status:   Feedback
+Status:   Open
 Bug Type: Program Execution
 Operating System: SCO 5.0.5
 PHP Version:  4.4.0
 New Comment:

# gdb httpd
GNU gdb 5.2
Copyright 2002 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and
you are
welcome to change it and/or distribute copies of it under certain
conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for
details.
This GDB was configured as "i386-pc-sco3.2v5.0.5"...
(gdb) run -X
Starting program: /usr/local/apache133/bin/httpd -X

Program received signal SIGSEGV, Segmentation fault.
0x0806932d in _efree (ptr=warning: Cannot convert floating-point
register value to non-floating-point type.
0x0)
at /u/leroy/php4-STABLE-200508081638/Zend/zend_alloc.c:259
259 REMOVE_POINTER_FROM_LIST(p);
(gdb) bt
#0  0x0806932d in _efree (ptr=warning: Cannot convert floating-point
register value to non-floating-point type.
0x0)
at /u/leroy/php4-STABLE-200508081638/Zend/zend_alloc.c:259
(gdb)


Previous Comments:


[2005-09-01 23:03:41] [EMAIL PROTECTED]

And what do you mean with optimizer? Are you using your own flags
during compile? Something like -O3 ?




[2005-09-01 23:02:51] [EMAIL PROTECTED]

Are you or are you not going to provide a short reproducing script? If
you're not, let this report rot.




[2005-09-01 22:40:06] ljanda at checkstop dot com

This uses full optimization, correct. I can play with the different
levels.



[2005-09-01 22:37:06] ljanda at checkstop dot com

Ok, got gdb for SCO and compile it.
Compile PHP --enable-debug, and now it is working.

Something in the optimizer.



[2005-09-01 20:58:16] ljanda at checkstop dot com

Any ideas where I can put statements to log, and try to narrow down
where the problem is occuring.

I think it is in exec.c.



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

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


#34344 [Opn->Bgs]: register_shutdown_function() in classes

2005-09-02 Thread sniper
 ID:   34344
 Updated by:   [EMAIL PROTECTED]
 Reported By:  thomas at ecommerce dot com
-Status:   Open
+Status:   Bogus
 Bug Type: SPL related
 Operating System: SuSE Linux
 PHP Version:  5.0.4
 New Comment:

Ah yes, you can't really call any object methods inside a shutdown
function since the objects are destructed before that.


Previous Comments:


[2005-09-02 16:27:45] thomas at ecommerce dot com

Script start! Init Class.
Class init call!
Registrering shutdown function..
done
Class inited!

Warning: (Registered shutdown functions) Unable to call
TestClass::_log() - function does not exist in Unknown on line 0
--
This is the output with the latest CVS Snap. The problem still exists
and the Error Message is wrong ( function does not exist, but exists )



[2005-09-02 16:15:12] [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-02 12:54:14] thomas at ecommerce dot com

Script start! Init Class.
Class init call!
Registrering shutdown function..
done
Class inited!

Fatal error: Call to private method TestClass::_log() from context ''
in Unknown on line 0
--
is the current result



[2005-09-02 12:53:19] thomas at ecommerce dot com

Updated Expected result part



[2005-09-02 12:48:51] thomas at ecommerce dot com

Description:

When trying to call the register_shutdown_function() inside class like
this:

register_shutdown_function(array(&$this, "_log"));

and the method _log() is a private method it don't work. We assign
$this here to the function so 
register_shutdown_function() should be allowed to call a private
function inside of the class or at least throw allready here an error
message when this function is called and _log() is a private function.
Its also not documented that this wouldn't work

Reproduce code:
---
_init();
}

private function _init()
{
echo "Registrering shutdown function..\n";

//-- register log function
register_shutdown_function(array(&$this, "_log"));

echo "done\n";
}

private function _log()
{
//-- send mail
mail("[EMAIL PROTECTED]", "subject", "content");
}
}

echo "Script start! Init Class.\n";
$TestClass = new TestClass();
echo "Class inited!\n";

Expected result:

email will be send to [EMAIL PROTECTED] when script is done.

Actual result:
--
Script will not call the shutdown function





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


#34312 [Fbk->Csd]: segfault in 5.04

2005-09-02 Thread james at academicsuperstore dot com
 ID:   34312
 User updated by:  james at academicsuperstore dot com
 Reported By:  james at academicsuperstore dot com
-Status:   Feedback
+Status:   Closed
 Bug Type: Reproducible crash
 Operating System: Debian 3.1 Linux 2.4.29
 PHP Version:  5.0.4
 New Comment:

Thanks, everything works as expected and the segfault is fixed.  When
will 5.0.5 be out?


Previous Comments:


[2005-09-02 07:24:39] [EMAIL PROTECTED]

And FYI: PHP touches httpd.conf when you do 'make install'..




[2005-09-02 07:24:10] [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

Try newer snapshot.



[2005-09-02 01:45:36] james at academicsuperstore dot com

I didn't touch my httpd.conf.  I literally did a ./configure, make,
make install, apachectl restart.  Plus even running just the cli php is
borked, exits with message 1 no matter what options it is given.

Even something like:
php -r "echo 'test';"

just exits with message 1 and no output.



[2005-09-01 23:48:50] [EMAIL PROTECTED]

Check your httpd.conf that PHP is really enabled..




[2005-09-01 20:57:56] james at academicsuperstore dot com

When I configure, make, make install using the same configure line as
before I am left with a nonfunctioning php.  Hitting php pages just
produces a white screen.  Even the cli php exits with code 1.  There
are no cores or errors in the log.  Was something between 5.0.4 and the
snapshot broken?  Sorry I can't test the fix.



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

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


#34344 [Fbk->Opn]: register_shutdown_function() in classes

2005-09-02 Thread thomas at ecommerce dot com
 ID:   34344
 User updated by:  thomas at ecommerce dot com
 Reported By:  thomas at ecommerce dot com
-Status:   Feedback
+Status:   Open
 Bug Type: SPL related
 Operating System: SuSE Linux
 PHP Version:  5.0.4
 New Comment:

Script start! Init Class.
Class init call!
Registrering shutdown function..
done
Class inited!

Warning: (Registered shutdown functions) Unable to call
TestClass::_log() - function does not exist in Unknown on line 0
--
This is the output with the latest CVS Snap. The problem still exists
and the Error Message is wrong ( function does not exist, but exists )


Previous Comments:


[2005-09-02 16:15:12] [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-02 12:54:14] thomas at ecommerce dot com

Script start! Init Class.
Class init call!
Registrering shutdown function..
done
Class inited!

Fatal error: Call to private method TestClass::_log() from context ''
in Unknown on line 0
--
is the current result



[2005-09-02 12:53:19] thomas at ecommerce dot com

Updated Expected result part



[2005-09-02 12:48:51] thomas at ecommerce dot com

Description:

When trying to call the register_shutdown_function() inside class like
this:

register_shutdown_function(array(&$this, "_log"));

and the method _log() is a private method it don't work. We assign
$this here to the function so 
register_shutdown_function() should be allowed to call a private
function inside of the class or at least throw allready here an error
message when this function is called and _log() is a private function.
Its also not documented that this wouldn't work

Reproduce code:
---
_init();
}

private function _init()
{
echo "Registrering shutdown function..\n";

//-- register log function
register_shutdown_function(array(&$this, "_log"));

echo "done\n";
}

private function _log()
{
//-- send mail
mail("[EMAIL PROTECTED]", "subject", "content");
}
}

echo "Script start! Init Class.\n";
$TestClass = new TestClass();
echo "Class inited!\n";

Expected result:

email will be send to [EMAIL PROTECTED] when script is done.

Actual result:
--
Script will not call the shutdown function





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


#34233 [Opn->Asn]: PDO pgsql driver ignores parameters when surrounded by closed quotes

2005-09-02 Thread sniper
 ID:   34233
 Updated by:   [EMAIL PROTECTED]
-Summary:  PDO ignores parameters when surrounded by closed
   quotes
 Reported By:  php at sagi dot org
-Status:   Open
+Status:   Assigned
 Bug Type: PDO related
-Operating System: Linux
+Operating System: *
-PHP Version:  5.1.0RC1
+PHP Version:  5CVS-2005-09-02
 Assigned To:  wez


Previous Comments:


[2005-09-02 11:23:38] php at sagi dot org

Problem still exists with php5-200509020830, pgsql driver. 

Did not test with any other driver.



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

This works for me in current PHP_5_1 branch using SQLite.



[2005-08-24 13:23:57] php at sagi dot org

Description:

Running PHP5.1.0RC1, postgresql 8 server with v7.4.7 client libs
(pretty sure native prepared statements are disabled).

When trying to execute this query:
$stmt = $db->prepare("SELECT ('0' || :param || '0')");
$stmt->execute(array(':param' => 123));

PDO actually executes this SQL statement: SELECT ('0' || :param ||
'0'), without replacing :param.

It seems like the parser thinks the whole "0' || :param || '0" part is
quoted, though its not.

The query "SELECT (0 || :param || 0)" works as expected.






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


#34342 [Opn->Bgs]: Cannot find MySQL header files

2005-09-02 Thread sniper
 ID:   34342
 Updated by:   [EMAIL PROTECTED]
 Reported By:  v88v at vlasaty dot at
-Status:   Open
+Status:   Bogus
 Bug Type: MySQL related
 Operating System: suse 9.2
 PHP Version:  5.0.4
 New Comment:

Yeah, you got it right. (no bug here)



Previous Comments:


[2005-09-02 12:07:09] v88v at vlasaty dot at

Description:

./configure --with-apxs2=/usr/local/apache2/bin/apxs 
--with-mysql 
 
The problem can be fixed with mysql-path as parameter - 
without the include-directory! 
 
./configure --with-apxs2=/usr/local/apache2/bin/apxs 
--with-mysql=/usr/local/mysql 






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


#34343 [Opn->Bgs]: Huge memory leaks in ISAPI

2005-09-02 Thread sniper
 ID:   34343
 Updated by:   [EMAIL PROTECTED]
 Reported By:  jakub at icewarp dot com
-Status:   Open
+Status:   Bogus
 Bug Type: IIS related
 Operating System: Any
 PHP Version:  4.4.0
 New Comment:

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

Thank you for your interest in PHP.




Previous Comments:


[2005-09-02 12:28:10] jakub at icewarp dot com

Description:

Since PHP 3.0 there is a huge memory leak in the ISAPI module. Probably
it is inside of the PHP core itself.
It is very easy to reproduce it. A simple



code leaks about 28MB after 200 calls.

Please, somebody fix it. Take your precious time, create an ISAPI
extension call to PHP ISAPI DLLm pass it info.html and loop it 200
times and find the memory leak...

>From what I saw PHP 4.4.0 is faster than previous versions but seem to
leak more.

I'm willing to help anyway I can. Thank you






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


#34344 [Opn->Fbk]: register_shutdown_function() in classes

2005-09-02 Thread sniper
 ID:   34344
 Updated by:   [EMAIL PROTECTED]
 Reported By:  thomas at ecommerce dot com
-Status:   Open
+Status:   Feedback
 Bug Type: SPL related
 Operating System: SuSE Linux
 PHP Version:  5.0.4
 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-09-02 12:54:14] thomas at ecommerce dot com

Script start! Init Class.
Class init call!
Registrering shutdown function..
done
Class inited!

Fatal error: Call to private method TestClass::_log() from context ''
in Unknown on line 0
--
is the current result



[2005-09-02 12:53:19] thomas at ecommerce dot com

Updated Expected result part



[2005-09-02 12:48:51] thomas at ecommerce dot com

Description:

When trying to call the register_shutdown_function() inside class like
this:

register_shutdown_function(array(&$this, "_log"));

and the method _log() is a private method it don't work. We assign
$this here to the function so 
register_shutdown_function() should be allowed to call a private
function inside of the class or at least throw allready here an error
message when this function is called and _log() is a private function.
Its also not documented that this wouldn't work

Reproduce code:
---
_init();
}

private function _init()
{
echo "Registrering shutdown function..\n";

//-- register log function
register_shutdown_function(array(&$this, "_log"));

echo "done\n";
}

private function _log()
{
//-- send mail
mail("[EMAIL PROTECTED]", "subject", "content");
}
}

echo "Script start! Init Class.\n";
$TestClass = new TestClass();
echo "Class inited!\n";

Expected result:

email will be send to [EMAIL PROTECTED] when script is done.

Actual result:
--
Script will not call the shutdown function





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


#34307 [Csd->Ctl]: OnUpdateStringUnempty INI options can be set empty

2005-09-02 Thread sniper
 ID:   34307
 Updated by:   [EMAIL PROTECTED]
 Reported By:  michael at zend dot com
-Status:   Closed
+Status:   Critical
-Bug Type: Reproducible crash
+Bug Type: Scripting Engine problem
-Operating System: Linux x86
+Operating System: *
-PHP Version:  5.1.0RC1
+PHP Version:  5CVS, 4CVS, 6CVS (2005-09-02
 Assigned To:  sniper
 New Comment:

My patch didn't work properly. The whole ini thing is a mess.



Previous Comments:


[2005-09-01 16:44:26] [EMAIL PROTECTED]

Fixed in HEAD and PHP_5_1 branches.



[2005-09-01 09:54:21] michael at zend dot com

Yes, this patch fixes it.



[2005-08-31 10:31:30] [EMAIL PROTECTED]

This patch fixes the ini mess:

  http://www.php.net/~jani/patches/ini_fix.patch

Can you try it out and confirm that it fixes it?




[2005-08-31 08:33:28] [EMAIL PROTECTED]

This is interesting since you shouldn't even be able to set that option
as empty..




[2005-08-30 14:32:39] michael at zend dot com

Backtrace:
--
(gdb) r -c ./ -q test.php 
Starting program: /home/michael/phprepos/php-5.1.0/sapi/cli/php -c ./
-q test.php

Program received signal SIGSEGV, Segmentation fault.
0x08101649 in _php_mb_encoding_handler_ex (info=0xbfffce40, arg=0x0,
res=0x8616854 "1")
at /home/michael/phprepos/php-5.1.0/ext/mbstring/mb_gpc.c:223
223 for (s2=info->separator; *s2 != '\0'; s2++) {
(gdb) bt
#0  0x08101649 in _php_mb_encoding_handler_ex (info=0xbfffce40,
arg=0x0, res=0x8616854 "1")
at /home/michael/phprepos/php-5.1.0/ext/mbstring/mb_gpc.c:223
#1  0x080f9f67 in zif_mb_parse_str (ht=1, return_value=0x862336c,
return_value_ptr=0x0, this_ptr=0x0, return_value_used=0)
at /home/michael/phprepos/php-5.1.0/ext/mbstring/mbstring.c:1396
#2  0x082f5bf9 in zend_do_fcall_common_helper_SPEC
(execute_data=0xbfffcf50) at zend_vm_execute.h:184
#3  0x082f8c09 in ZEND_DO_FCALL_SPEC_CONST_HANDLER
(execute_data=0xbfffcf50) at zend_vm_execute.h:1586
#4  0x082f587a in execute (op_array=0x8623bcc) at zend_vm_execute.h:87
#5  0x082caa35 in zend_execute_scripts (type=8, retval=0x0,
file_count=3) at /home/michael/phprepos/php-5.1.0/Zend/zend.c:1078
#6  0x08280d98 in php_execute_script (primary_file=0xb3c0) at
/home/michael/phprepos/php-5.1.0/main/main.c:1672
#7  0x083430e4 in main (argc=5, argv=0xb494) at
/home/michael/phprepos/php-5.1.0/sapi/cli/php_cli.c:1039

Configuration:

'./configure' \
'--enable-mbstring' \
'--disable-cgi' \
'--enable-debug' \
'--without-pear'



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

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


#32223 [Fbk->Opn]: weird behaviour of pg_last_notice

2005-09-02 Thread valiak at gmail dot com
 ID:   32223
 User updated by:  valiak at gmail dot com
 Reported By:  valiak at gmail dot com
-Status:   Feedback
+Status:   Open
 Bug Type: PostgreSQL related
 Operating System: *
-PHP Version:  5CVS-2005-05-14
+PHP Version:  php5-200509021030
 New Comment:

still do not work correctly, there is no output even with 
E_ALL


Previous Comments:


[2005-08-30 13:05:52] [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

And set error_reporting to E_ALL..




[2005-03-08 13:28:02] valiak at gmail dot com

if you switch the places of include_once and define there is no bug

there is no difference in the behaviour if include_once is changed to
include or require_once or require



[2005-03-07 18:13:54] valiak at gmail dot com

Description:

i've tried to localize to as smallest code as I could
the correct result happens even if you comment the include line or the
global directive or not using exceptions ... (there are few other
modifications too)

it happens with the cli version and with the apache module version

[EMAIL PROTECTED] ~/tmp/pg_last_notice
$ php -v
PHP 5.0.3 (cli) (built: Mar  2 2005 13:13:40)
Copyright (c) 1997-2004 The PHP Group
Zend Engine v2.0.3, Copyright (c) 1998-2004 Zend Technologies

compiled with
./configure --with-gettext --with-oci8 --with-apxs=/usr/bin/apxs
--with-gd --with-pgsql --with-readline --with-zlib --with-mysql=/usr
--with-
jpeg-dir --with-png-dir --enable-mbstring --enable-sockets
--enable-pcntl --enable-sigchild --with-exec-dir=/usr/bin
--with-config-file-path=
/etc/php5


pgsql

PostgreSQL Support => enabled
PostgreSQL(libpq) Version => 8.0.1
Multibyte character support => enabled
SSL support => disabled
Active Persistent Links => 0
Active Links => 0

Directive => Local Value => Master Value
pgsql.allow_persistent => Off => Off
pgsql.auto_reset_persistent => Off => Off
pgsql.ignore_notice => Off => Off
pgsql.log_notice => Off => Off
pgsql.max_links => Unlimited => Unlimited
pgsql.max_persistent => Unlimited => Unlimited


if some more info is needed tell me what to do?

Reproduce code:
---
[EMAIL PROTECTED] ~/tmp/pg_last_notice
$ cat test.inc.php

[EMAIL PROTECTED] ~/tmp/pg_last_notice
$ cat test.php
getMessage(), 1;
}

?>


Expected result:

[EMAIL PROTECTED] ~/tmp/pg_last_notice
$ php test.php
NOTICE:  11


Actual result:
--
[EMAIL PROTECTED] ~/tmp/pg_last_notice
$ php test.php
1






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


#34345 [NEW]: Extend ArrayObject::setFlags functionality

2005-09-02 Thread stochnagara at hotmail dot com
From: stochnagara at hotmail dot com
Operating system: windows xp
PHP version:  5CVS-2005-09-02 (snap)
PHP Bug Type: Feature/Change Request
Bug description:  Extend ArrayObject::setFlags functionality

Description:

ArrayObject has a method called setFlags. This method is still not
documented (set bug #34101). Anyway, I found out what is its possible
purpose - if the passed parameter is an even number then ArrayObject's
internal array values are printed in var_dump and if the passed parameter
is an odd number then object properties of the class which extends
ArrayObject are show. (See also bug #33799).

But I suggest setFlags fills another gap: set possible values to be 0, 1
or 2. 0 and 1 keep old functionality and 2 allows var_dump to print both
internal array values and properties of the class.

Reproduce code:
---
var = 'override';
$this['internal'] = 'base';
}
}

$foo = new dummy();
for ($i = 0; $i < 3; $i++) {
$foo->setFlags ($i);
var_dump($foo);
}


Expected result:

object(dummy)#1 (1) {
  ["internal"]=>
  string(4) "base"
}
object(dummy)#1 (1) {
  ["var"]=>
  string(8) "override"
}
object(dummy)#1 (2) {
  ["internal"]=>
  string(4) "base",
  ["var"]=>
  string(8) "override"
}


Actual result:
--
object(dummy)#1 (1) {
  ["internal"]=>
  string(4) "base"
}
object(dummy)#1 (1) {
  ["var"]=>
  string(8) "override"
}
object(dummy)#1 (1) {
  ["internal"]=>
  string(4) "base"
}


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


#34344 [Opn]: register_shutdown_function() in classes

2005-09-02 Thread thomas at ecommerce dot com
 ID:   34344
 User updated by:  thomas at ecommerce dot com
 Reported By:  thomas at ecommerce dot com
 Status:   Open
 Bug Type: SPL related
 Operating System: SuSE Linux
 PHP Version:  5.0.4
 New Comment:

Script start! Init Class.
Class init call!
Registrering shutdown function..
done
Class inited!

Fatal error: Call to private method TestClass::_log() from context ''
in Unknown on line 0
--
is the current result


Previous Comments:


[2005-09-02 12:53:19] thomas at ecommerce dot com

Updated Expected result part



[2005-09-02 12:48:51] thomas at ecommerce dot com

Description:

When trying to call the register_shutdown_function() inside class like
this:

register_shutdown_function(array(&$this, "_log"));

and the method _log() is a private method it don't work. We assign
$this here to the function so 
register_shutdown_function() should be allowed to call a private
function inside of the class or at least throw allready here an error
message when this function is called and _log() is a private function.
Its also not documented that this wouldn't work

Reproduce code:
---
_init();
}

private function _init()
{
echo "Registrering shutdown function..\n";

//-- register log function
register_shutdown_function(array(&$this, "_log"));

echo "done\n";
}

private function _log()
{
//-- send mail
mail("[EMAIL PROTECTED]", "subject", "content");
}
}

echo "Script start! Init Class.\n";
$TestClass = new TestClass();
echo "Class inited!\n";

Expected result:

email will be send to [EMAIL PROTECTED] when script is done.

Actual result:
--
Script will not call the shutdown function





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


#34344 [Opn]: register_shutdown_function() in classes

2005-09-02 Thread thomas at ecommerce dot com
 ID:   34344
 User updated by:  thomas at ecommerce dot com
 Reported By:  thomas at ecommerce dot com
 Status:   Open
 Bug Type: SPL related
 Operating System: SuSE Linux
 PHP Version:  5.0.4
 New Comment:

Updated Expected result part


Previous Comments:


[2005-09-02 12:48:51] thomas at ecommerce dot com

Description:

When trying to call the register_shutdown_function() inside class like
this:

register_shutdown_function(array(&$this, "_log"));

and the method _log() is a private method it don't work. We assign
$this here to the function so 
register_shutdown_function() should be allowed to call a private
function inside of the class or at least throw allready here an error
message when this function is called and _log() is a private function.
Its also not documented that this wouldn't work

Reproduce code:
---
_init();
}

private function _init()
{
echo "Registrering shutdown function..\n";

//-- register log function
register_shutdown_function(array(&$this, "_log"));

echo "done\n";
}

private function _log()
{
//-- send mail
mail("[EMAIL PROTECTED]", "subject", "content");
}
}

echo "Script start! Init Class.\n";
$TestClass = new TestClass();
echo "Class inited!\n";

Expected result:

email will be send to [EMAIL PROTECTED] when script is done.

Actual result:
--
Script will not call the shutdown function





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


#34344 [NEW]: register_shutdown_function() in classes

2005-09-02 Thread thomas at ecommerce dot com
From: thomas at ecommerce dot com
Operating system: SuSE Linux
PHP version:  5.0.4
PHP Bug Type: SPL related
Bug description:  register_shutdown_function() in classes

Description:

When trying to call the register_shutdown_function() inside class like
this:

register_shutdown_function(array(&$this, "_log"));

and the method _log() is a private method it don't work. We assign $this
here to the function so 
register_shutdown_function() should be allowed to call a private function
inside of the class or at least throw allready here an error message when
this function is called and _log() is a private function. Its also not
documented that this wouldn't work

Reproduce code:
---
_init();
}

private function _init()
{
echo "Registrering shutdown function..\n";

//-- register log function
register_shutdown_function(array(&$this, "_log"));

echo "done\n";
}

private function _log()
{
//-- send mail
mail("[EMAIL PROTECTED]", "subject", "content");
}
}

echo "Script start! Init Class.\n";
$TestClass = new TestClass();
echo "Class inited!\n";

Expected result:

email will be send to [EMAIL PROTECTED] when script is done.

Actual result:
--
Script will not call the shutdown function

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


#34343 [NEW]: Huge memory leaks in ISAPI

2005-09-02 Thread jakub at icewarp dot com
From: jakub at icewarp dot com
Operating system: Any
PHP version:  4.4.0
PHP Bug Type: IIS related
Bug description:  Huge memory leaks in ISAPI

Description:

Since PHP 3.0 there is a huge memory leak in the ISAPI module. Probably it
is inside of the PHP core itself.
It is very easy to reproduce it. A simple



code leaks about 28MB after 200 calls.

Please, somebody fix it. Take your precious time, create an ISAPI
extension call to PHP ISAPI DLLm pass it info.html and loop it 200 times
and find the memory leak...

>From what I saw PHP 4.4.0 is faster than previous versions but seem to
leak more.

I'm willing to help anyway I can. Thank you


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


#34342 [NEW]: Cannot find MySQL header files

2005-09-02 Thread v88v at vlasaty dot at
From: v88v at vlasaty dot at
Operating system: suse 9.2
PHP version:  5.0.4
PHP Bug Type: MySQL related
Bug description:  Cannot find MySQL header files

Description:

./configure --with-apxs2=/usr/local/apache2/bin/apxs 
--with-mysql 
 
The problem can be fixed with mysql-path as parameter - 
without the include-directory! 
 
./configure --with-apxs2=/usr/local/apache2/bin/apxs 
--with-mysql=/usr/local/mysql 


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


#34304 [Asn->Csd]: Date('w') return wrong number for sunday. Maybe a new week day parameter is req.

2005-09-02 Thread derick
 ID:   34304
 Updated by:   [EMAIL PROTECTED]
 Reported By:  sandved at gmail dot com
-Status:   Assigned
+Status:   Closed
 Bug Type: Feature/Change Request
 Operating System: *
 PHP Version:  6CVS, 5CVS, 4CVS
 Assigned To:  derick
 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.

Fixed for PHP 5.1 and 6 by adding the "N" modifier.


Previous Comments:


[2005-08-30 16:23:55] [EMAIL PROTECTED]

Yeah, but it's not a bug but missing feature.




[2005-08-30 12:42:22] sandved at gmail dot com

Is it possible then to add a (ISO day) parameter which return 1 for
monday, 2 for tuesday, ..., 6 for saturday and 7 for sunday?



[2005-08-30 12:28:11] [EMAIL PROTECTED]

It's returning what it's documented to return. (it is not some ISO
standard it complies to but the PHP manual)




[2005-08-30 12:11:25] sandved at gmail dot com

Description:

The Date function have a day of the week parameter 'w'

This parameter should return 7 for sundays, not 0 to be ISO 8601
compilant

Why

http://se.php.net/date :
> w   Numeric representation of the day of the week 
> 0 (for Sunday) through 6 (for Saturday)

This week parameter do not return leading zeros when used like
Date('o\WWw'), Date('o\-\WW\-w')

According to ISO 8601 monday is the first day of the week and sunday
the last, numbereded 1 to 7

(Section 5.2.3 Week date states
In expressions of week dates
- day of the week is represented by one decimal digit. Monday shall be
identified as day [1] of any calendar
week, and subsequent days of the same week shall be numbered in
ascending sequence to Sunday (day [7]).) like:

Date   - Week (extended format -Www-D)
-- - --
1997-12-29 - 1998-W01-1
1998-01-04 - 1998-W01-7
1998-01-01 - 1998-W01-4
1998-12-31 - 1998-W53-4
1992-01-01 - 1992-W01-3
1992-02-29 - 1992-W09-6
1992-12-31 - 1992-W53-4
1975-01-01 - 1975-W01-3
1975-12-28 - 1975-W52-7
1975-12-29 - 1976-W01-1


Sources
Here's a copy of the latest free online copy
http://www.pvv.org/~nsaa/8601v2000.pdf, only minor changes in the text
in the latest version from ISO - also see
http://en.wikipedia.org/wiki/ISO_8601.


Reproduce code:
---
Echo Date('o\-\WW\-w', strtotime('2 January 2005'))
Date('o\-\WW\-w', strtotime('9 January 2005'));


Expected result:

2004-W53-7
2005-W01-7

Actual result:
--
2004-W53-0
2005-W1-0 (leading zeros in week fixed in bug report
http://bugs.php.net/?id=34302)





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


#34233 [Fbk->Opn]: PDO ignores parameters when surrounded by closed quotes

2005-09-02 Thread php at sagi dot org
 ID:   34233
 User updated by:  php at sagi dot org
 Reported By:  php at sagi dot org
-Status:   Feedback
+Status:   Open
 Bug Type: PDO related
 Operating System: Linux
 PHP Version:  5.1.0RC1
 Assigned To:  wez
 New Comment:

Problem still exists with php5-200509020830, pgsql driver. 

Did not test with any other driver.


Previous Comments:


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

This works for me in current PHP_5_1 branch using SQLite.



[2005-08-24 13:23:57] php at sagi dot org

Description:

Running PHP5.1.0RC1, postgresql 8 server with v7.4.7 client libs
(pretty sure native prepared statements are disabled).

When trying to execute this query:
$stmt = $db->prepare("SELECT ('0' || :param || '0')");
$stmt->execute(array(':param' => 123));

PDO actually executes this SQL statement: SELECT ('0' || :param ||
'0'), without replacing :param.

It seems like the parser thinks the whole "0' || :param || '0" part is
quoted, though its not.

The query "SELECT (0 || :param || 0)" works as expected.






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


#34333 [Fbk->Csd]: PHP5.1 crash / immediate exit

2005-09-02 Thread php at sagi dot org
 ID:   34333
 User updated by:  php at sagi dot org
 Reported By:  php at sagi dot org
-Status:   Feedback
+Status:   Closed
 Bug Type: Reproducible crash
 Operating System: Linux
 PHP Version:  5CVS-2005-09-01 (CVS)
 New Comment:

Works with php5-200509020830, even with full configuration.


Previous Comments:


[2005-09-02 00:23:13] [EMAIL PROTECTED]

Can not reproduce. Try with latest CVS as of now and use this configure
line:

# ./configure --disable-all \
--prefix=/usr/local/php5 \
--with-apxs2=/usr/bin/apxs2

And make sure you don't have multiple LoadModule lines or disabled such
in your httpd.conf. 

And if "php -v" doesn't seem to work, try "php -n -v"


 



[2005-09-01 19:42:57] php at sagi dot org

Description:

I'm trying to run the latest snapshot, php5-200509011630, on i686
machine running debian sarge, apache2 sapi.

It compiles without any problem, but 'make install' fails with the
following:
Installing PEAR environment:  /usr/local/php5/share/pear/
make[1]: *** [install-pear-installer] Error 1
make: *** [install-pear] Error 2

It seems like the CLI bin and the apache2 module were installed, but
when running php -v, the program just exists (no crash):
[EMAIL PROTECTED]:~# /usr/local/php5/bin/php -v
[EMAIL PROTECTED]:~#

GDB output:
(gdb) run
Starting program: /usr/local/php5/bin/php
[Thread debugging using libthread_db enabled]
[New Thread 1076854912 (LWP 1377)]

Program exited with code 01.
(gdb) 

Strace:
http://beep.boom.org.il/~sagi/bugs/php5_200509011630_strace.txt

When running as apache2 module, it crashes immediately when getting the
first PHP request. Backtrace:

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 1079532448 (LWP 1394)]
0x40884031 in php_handler (r=0x81ce510) at
/usr/local/src/php5-200509011630/sapi/apache2handler/sapi_apache2.c:496
496 if (!AP2(engine)) {
(gdb) bt
#0  0x40884031 in php_handler (r=0x81ce510) at
/usr/local/src/php5-200509011630/sapi/apache2handler/sapi_apache2.c:496
#1  0x080783a5 in ap_run_handler ()
#2  0x080789b0 in ap_invoke_handler ()
#3  0x08069c9a in ap_process_request ()
#4  0x0806512d in _start ()
#5  0x081ce510 in ?? ()
#6  0x0004 in ?? ()
#7  0x081ce510 in ?? ()
#8  0x0808373c in ap_run_pre_connection ()
#9  0x080835f5 in ap_run_process_connection ()
#10 0x080769a4 in ap_graceful_stop_signalled ()
#11 0x08076bbb in ap_graceful_stop_signalled ()
#12 0x08076c18 in ap_graceful_stop_signalled ()
#13 0x0807748a in ap_mpm_run ()
#14 0x0807dabd in main ()
(gdb)

PHP was configured with the following parameters:
./configure \
--prefix=/usr/local/php5 \
--with-apxs2=/usr/bin/apxs2 \
--with-zlib \
--with-mysql=shared \
--with-pgsql=shared \
--with-sqlite=shared \
--with-pdo=shared \
--with-pdo-pgsql=shared \
--with-pdo-mysql=shared \
--with-pdo-sqlite=shared \
--with-pear=/usr/local/php5/share/pear \
--with-xmlrpc \
--enable-soap \
--with-gettext=shared \
--with-gd=shared \
--with-jpeg-dir=shared,/usr \
--with-xsl=shared \
--enable-memory-limit

php-5.1.0RC1 works without any problems with the very same
configuration on the same machine.






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


#32301 [Fbk->Opn]: PHP hangs during decompression

2005-09-02 Thread ralph at cs dot cf dot ac dot uk
 ID:   32301
 User updated by:  ralph at cs dot cf dot ac dot uk
 Reported By:  ralph at cs dot cf dot ac dot uk
-Status:   Feedback
+Status:   Open
 Bug Type: Zlib Related
 Operating System: MacOS X 10.3.x
 PHP Version:  5CVS-2005-03-30
 New Comment:

New test:

sudo pear install Image_Barcode


Previous Comments:


[2005-09-02 10:36:18] [EMAIL PROTECTED]

So you need to come up with a better test script..




[2005-09-02 10:08:09] ralph at cs dot cf dot ac dot uk

Hmm. there is something odd going on here.

This snapshot does solve the problem on MacOS X 10.4.2 for 
the test case reported.

However, the original source of the problem was when 
installing stuff with PEAR, and that STILL does NOT work.

E.g.  sudo pear install Image_Barcode
downloading Image_Barcode-1.0.4.tgz ...
Starting to download Image_Barcode-1.0.4.tgz (13,150 bytes)
.done: 13,150 bytes

Hangs, processor running flat out, until aborted with CTRL-
C.

Before, after a long discussion with the PEAR folks, they 
produced the test case reported here to show it was not a 
PEAR bug.

Unfortunately, the fix so far seems to fix the test case, 
but not the real problem to be addressed!



[2005-09-02 08:53:26] [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

And don't invent your own PHP versions. The version string in the bug
reports must start with a NUMBER..




[2005-03-30 15:45:59] ralph at cs dot cf dot ac dot uk

Have tried this with 
php5-200503301230

Bug is still present.



[2005-03-18 19:31:59] [EMAIL PROTECTED]

2nd try:

  http://snaps.php.net/php5-latest.tar.gz

(for your convinience I removed the url for the win32
binaries..*SIGH*)

There's nothing wrong with the snapshot, I checked it myself.





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

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


#34311 [Asn->Opn]: unserialize() causes php to segfault

2005-09-02 Thread derick
 ID:   34311
 Updated by:   [EMAIL PROTECTED]
 Reported By:  marco at storm dot ee
-Status:   Assigned
+Status:   Open
 Bug Type: Reproducible crash
 Operating System: *
 PHP Version:  5CVS, 4CVS (2005-08-31)
 Assigned To:  derick
 New Comment:

Forget it, this stuff is written in such a way I don't want to debug it
:)


Previous Comments:


[2005-09-02 10:24:00] [EMAIL PROTECTED]

I'll have a look.



[2005-09-02 10:14:10] [EMAIL PROTECTED]

I am not able to fix this. Probably this is re2c bug.



[2005-09-02 09:57:46] [EMAIL PROTECTED]

Dmitry, can you see if you can do anything about this?
(the serializer crashes with any char outside US-ASCII :)




[2005-08-31 16:41:08] [EMAIL PROTECTED]

Short reproducing script:

# php -r 'unserialize("å");'

(that's a with ring above it :)





[2005-08-31 14:54:34] [EMAIL PROTECTED]

0x08339834 in php_var_unserialize (rval=0xbfffce64, p=0xbfffce44,
max=0x89d8e4d "", var_hash=0xbfffce48) at :449
449 : No such file or directory.
in 
(gdb) bt
#0  0x08339834 in php_var_unserialize (rval=0xbfffce64, p=0xbfffce44,
max=0x89d8e4d "", var_hash=0xbfffce48) at :449
#1  0x0832d916 in zif_unserialize (ht=1, return_value=0x89d2ddc,
return_value_ptr=0x0, this_ptr=0x0, return_value_used=0)
at /usr/src/php/php_5_1/ext/standard/var.c:866
#2  0x083d9c7f in zend_do_fcall_common_helper_SPEC
(execute_data=0xbfffcfa0) at zend_vm_execute.h:184
#3  0x083de12e in ZEND_DO_FCALL_SPEC_CONST_HANDLER
(execute_data=0xbfffcfa0) at zend_vm_execute.h:1588
#4  0x083d9960 in execute (op_array=0x89d361c) at zend_vm_execute.h:87
#5  0x083b32c5 in zend_execute_scripts (type=8, retval=0x0,
file_count=3) at /usr/src/php/php_5_1/Zend/zend.c:1078
#6  0x083719a9 in php_execute_script (primary_file=0xb3e0) at
/usr/src/php/php_5_1/main/main.c:1682
#7  0x08428f36 in main (argc=2, argv=0xb4b4) at
/usr/src/php/php_5_1/sapi/cli/php_cli.c:1039




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

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


#32301 [Opn->Fbk]: PHP hangs during decompression

2005-09-02 Thread sniper
 ID:   32301
 Updated by:   [EMAIL PROTECTED]
 Reported By:  ralph at cs dot cf dot ac dot uk
-Status:   Open
+Status:   Feedback
 Bug Type: Zlib Related
 Operating System: MacOS X 10.3.x
 PHP Version:  5CVS-2005-03-30
 New Comment:

So you need to come up with a better test script..



Previous Comments:


[2005-09-02 10:08:09] ralph at cs dot cf dot ac dot uk

Hmm. there is something odd going on here.

This snapshot does solve the problem on MacOS X 10.4.2 for 
the test case reported.

However, the original source of the problem was when 
installing stuff with PEAR, and that STILL does NOT work.

E.g.  sudo pear install Image_Barcode
downloading Image_Barcode-1.0.4.tgz ...
Starting to download Image_Barcode-1.0.4.tgz (13,150 bytes)
.done: 13,150 bytes

Hangs, processor running flat out, until aborted with CTRL-
C.

Before, after a long discussion with the PEAR folks, they 
produced the test case reported here to show it was not a 
PEAR bug.

Unfortunately, the fix so far seems to fix the test case, 
but not the real problem to be addressed!



[2005-09-02 08:53:26] [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

And don't invent your own PHP versions. The version string in the bug
reports must start with a NUMBER..




[2005-03-30 15:45:59] ralph at cs dot cf dot ac dot uk

Have tried this with 
php5-200503301230

Bug is still present.



[2005-03-18 19:31:59] [EMAIL PROTECTED]

2nd try:

  http://snaps.php.net/php5-latest.tar.gz

(for your convinience I removed the url for the win32
binaries..*SIGH*)

There's nothing wrong with the snapshot, I checked it myself.





[2005-03-14 14:42:35] ralph at cs dot cf dot ac dot uk

Description:

Running the following compression / decompression code 
on MacOS X results in php hanging, and control never 
being retuyrned to the user.

One particular side effect is that doing
sudo pear upgrade-all
does not install the upgrades and hangs. However, this 
problem appears to be in php itself, not pear.

Reproduce code:
---


Expected result:

OK Done!

on completion.

Actual result:
--
Never returns.





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


#34311 [Asn]: unserialize() causes php to segfault

2005-09-02 Thread derick
 ID:   34311
 Updated by:   [EMAIL PROTECTED]
 Reported By:  marco at storm dot ee
 Status:   Assigned
 Bug Type: Reproducible crash
 Operating System: *
 PHP Version:  5CVS, 4CVS (2005-08-31)
-Assigned To:  sniper
+Assigned To:  derick
 New Comment:

I'll have a look.


Previous Comments:


[2005-09-02 10:14:10] [EMAIL PROTECTED]

I am not able to fix this. Probably this is re2c bug.



[2005-09-02 09:57:46] [EMAIL PROTECTED]

Dmitry, can you see if you can do anything about this?
(the serializer crashes with any char outside US-ASCII :)




[2005-08-31 16:41:08] [EMAIL PROTECTED]

Short reproducing script:

# php -r 'unserialize("å");'

(that's a with ring above it :)





[2005-08-31 14:54:34] [EMAIL PROTECTED]

0x08339834 in php_var_unserialize (rval=0xbfffce64, p=0xbfffce44,
max=0x89d8e4d "", var_hash=0xbfffce48) at :449
449 : No such file or directory.
in 
(gdb) bt
#0  0x08339834 in php_var_unserialize (rval=0xbfffce64, p=0xbfffce44,
max=0x89d8e4d "", var_hash=0xbfffce48) at :449
#1  0x0832d916 in zif_unserialize (ht=1, return_value=0x89d2ddc,
return_value_ptr=0x0, this_ptr=0x0, return_value_used=0)
at /usr/src/php/php_5_1/ext/standard/var.c:866
#2  0x083d9c7f in zend_do_fcall_common_helper_SPEC
(execute_data=0xbfffcfa0) at zend_vm_execute.h:184
#3  0x083de12e in ZEND_DO_FCALL_SPEC_CONST_HANDLER
(execute_data=0xbfffcfa0) at zend_vm_execute.h:1588
#4  0x083d9960 in execute (op_array=0x89d361c) at zend_vm_execute.h:87
#5  0x083b32c5 in zend_execute_scripts (type=8, retval=0x0,
file_count=3) at /usr/src/php/php_5_1/Zend/zend.c:1078
#6  0x083719a9 in php_execute_script (primary_file=0xb3e0) at
/usr/src/php/php_5_1/main/main.c:1682
#7  0x08428f36 in main (argc=2, argv=0xb4b4) at
/usr/src/php/php_5_1/sapi/cli/php_cli.c:1039




[2005-08-30 23:16:03] [EMAIL PROTECTED]

I don't get a segfault, but valgrind does give the following errors:
==22613==
==22613== Invalid read of size 1
==22613==at 0x8113A04: php_stream_url_wrap_http_ex
(http_fopen_wrapper.c:406)
==22613==by 0x81142F5: php_stream_url_wrap_http
(http_fopen_wrapper.c:569)
==22613==by 0x814836D: _php_stream_open_wrapper_ex
(streams.c:2696)
==22613==by 0x80DF0DC: php_if_fopen (file.c:1143)
==22613==by 0x81731B6: execute (zend_execute.c:1675)
==22613==by 0x8164CB8: zend_execute_scripts (zend.c:938)
==22613==by 0x813BA3C: php_execute_script (main.c:1743)
==22613==by 0x8177A86: main (php_cli.c:828)
==22613==  Address 0x1B9A50F7 is 1 bytes before a block of size 1024
alloc'd
==22613==at 0x1B9042A6: malloc (vg_replace_malloc.c:130)
==22613==by 0x8112FCC: php_stream_url_wrap_http_ex
(http_fopen_wrapper.c:390)
==22613==by 0x81142F5: php_stream_url_wrap_http
(http_fopen_wrapper.c:569)
==22613==by 0x814836D: _php_stream_open_wrapper_ex
(streams.c:2696)
==22613==by 0x80DF0DC: php_if_fopen (file.c:1143)
==22613==by 0x81731B6: execute (zend_execute.c:1675)
==22613==by 0x8164CB8: zend_execute_scripts (zend.c:938)
==22613==by 0x813BA3C: php_execute_script (main.c:1743)
==22613==by 0x8177A86: main (php_cli.c:828)





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

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


#18949 [Bgs->Csd]: ITX: Minor mistake in 'placeholderExists()' ?

2005-09-02 Thread heino
 ID:   18949
 Updated by:   [EMAIL PROTECTED]
 Reported By:  heino at gehlsen dot dk
-Status:   Bogus
+Status:   Closed
 Bug Type: *General Issues
 Operating System: Debian 3.0
 PHP Version:  CVS (rev. 1.5)
 New Comment:

Now that was an old bugger.

Yes, it's PEAR-related (HTML_Template_IT), and was actually fixed back
in 2002, so it should of cause have been reclosed.

PS
PEAR had its own category in PHP's bug system back then...


Previous Comments:


[2005-09-02 08:40:03] [EMAIL PROTECTED]

No idea what this was about, assuming PEAR and it has it's own bug
system.




[2002-08-23 08:38:44] heino at gehlsen dot dk

This bug was kind of a double-bug, since the same typo was made two
times in the same function – both when $block is empty (fixed) and when
it is set (not fixed).

Sorry for the lack of detail...



[2002-08-23 06:58:06] [EMAIL PROTECTED]

This bug has been fixed in CVS.

In case this was a PHP problem, 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/.
 
In case this was a documentation problem, the fix will show up soon at
http://www.php.net/manual/.

In case this was a PHP.net website problem, the change will show
up on the PHP.net site and on the mirror sites in short time.
 
Thank you for the report, and for helping us make PHP better.





[2002-08-16 16:46:01] heino at gehlsen dot dk

I can't get placeholderExists() to work without making minor changes to
the code:

[...]
while (list($k, $variable) = each($variables)) 
-if ($variable == $placeholder) {
+if ($k == $placeholder) {
$found = $block;
[...]

(boolean) $variable != (string) $placeholder.
(string) $k = (string) $placeholder.

PS.
I don't have the time to check if it's placeholderExists() that is
buggy or if it is $this->blockvariables' - sorry...





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


#34311 [Asn]: unserialize() causes php to segfault

2005-09-02 Thread dmitry
 ID:   34311
 Updated by:   [EMAIL PROTECTED]
 Reported By:  marco at storm dot ee
 Status:   Assigned
 Bug Type: Reproducible crash
 Operating System: *
 PHP Version:  5CVS, 4CVS (2005-08-31)
-Assigned To:  dmitry
+Assigned To:  sniper
 New Comment:

I am not able to fix this. Probably this is re2c bug.


Previous Comments:


[2005-09-02 09:57:46] [EMAIL PROTECTED]

Dmitry, can you see if you can do anything about this?
(the serializer crashes with any char outside US-ASCII :)




[2005-08-31 16:41:08] [EMAIL PROTECTED]

Short reproducing script:

# php -r 'unserialize("å");'

(that's a with ring above it :)





[2005-08-31 14:54:34] [EMAIL PROTECTED]

0x08339834 in php_var_unserialize (rval=0xbfffce64, p=0xbfffce44,
max=0x89d8e4d "", var_hash=0xbfffce48) at :449
449 : No such file or directory.
in 
(gdb) bt
#0  0x08339834 in php_var_unserialize (rval=0xbfffce64, p=0xbfffce44,
max=0x89d8e4d "", var_hash=0xbfffce48) at :449
#1  0x0832d916 in zif_unserialize (ht=1, return_value=0x89d2ddc,
return_value_ptr=0x0, this_ptr=0x0, return_value_used=0)
at /usr/src/php/php_5_1/ext/standard/var.c:866
#2  0x083d9c7f in zend_do_fcall_common_helper_SPEC
(execute_data=0xbfffcfa0) at zend_vm_execute.h:184
#3  0x083de12e in ZEND_DO_FCALL_SPEC_CONST_HANDLER
(execute_data=0xbfffcfa0) at zend_vm_execute.h:1588
#4  0x083d9960 in execute (op_array=0x89d361c) at zend_vm_execute.h:87
#5  0x083b32c5 in zend_execute_scripts (type=8, retval=0x0,
file_count=3) at /usr/src/php/php_5_1/Zend/zend.c:1078
#6  0x083719a9 in php_execute_script (primary_file=0xb3e0) at
/usr/src/php/php_5_1/main/main.c:1682
#7  0x08428f36 in main (argc=2, argv=0xb4b4) at
/usr/src/php/php_5_1/sapi/cli/php_cli.c:1039




[2005-08-30 23:16:03] [EMAIL PROTECTED]

I don't get a segfault, but valgrind does give the following errors:
==22613==
==22613== Invalid read of size 1
==22613==at 0x8113A04: php_stream_url_wrap_http_ex
(http_fopen_wrapper.c:406)
==22613==by 0x81142F5: php_stream_url_wrap_http
(http_fopen_wrapper.c:569)
==22613==by 0x814836D: _php_stream_open_wrapper_ex
(streams.c:2696)
==22613==by 0x80DF0DC: php_if_fopen (file.c:1143)
==22613==by 0x81731B6: execute (zend_execute.c:1675)
==22613==by 0x8164CB8: zend_execute_scripts (zend.c:938)
==22613==by 0x813BA3C: php_execute_script (main.c:1743)
==22613==by 0x8177A86: main (php_cli.c:828)
==22613==  Address 0x1B9A50F7 is 1 bytes before a block of size 1024
alloc'd
==22613==at 0x1B9042A6: malloc (vg_replace_malloc.c:130)
==22613==by 0x8112FCC: php_stream_url_wrap_http_ex
(http_fopen_wrapper.c:390)
==22613==by 0x81142F5: php_stream_url_wrap_http
(http_fopen_wrapper.c:569)
==22613==by 0x814836D: _php_stream_open_wrapper_ex
(streams.c:2696)
==22613==by 0x80DF0DC: php_if_fopen (file.c:1143)
==22613==by 0x81731B6: execute (zend_execute.c:1675)
==22613==by 0x8164CB8: zend_execute_scripts (zend.c:938)
==22613==by 0x813BA3C: php_execute_script (main.c:1743)
==22613==by 0x8177A86: main (php_cli.c:828)





[2005-08-30 19:37:18] marco at storm dot ee

Description:

OS: Debian-AMD64, Linux 2.6.12.5
Configure line: configure --enable-debug --with-zlib

gdb:
Program terminated with signal 11, Segmentation fault.

#0  0x004ede39 in php_var_unserialize (rval=0x7fd4cc90,
p=0x7fd4cc58,
max=0x7bb831 "", var_hash=0x7fd4cc60)
at /home/marco/soft/php-4.4.0/ext/standard/var_unserializer.c:428
#1  0x004e5045 in zif_unserialize (ht=1, return_value=0x7b45e0,
this_ptr=0x0,
return_value_used=0) at
/home/marco/soft/php-4.4.0/ext/standard/var.c:716
#2  0x00570876 in execute (op_array=0x7b5200)
at /home/marco/soft/php-4.4.0/Zend/zend_execute.c:1672
#3  0x0055aa3d in zend_execute_scripts (type=8, retval=0x0,
file_count=3)
at /home/marco/soft/php-4.4.0/Zend/zend.c:938
#4  0x0051f878 in php_execute_script
(primary_file=0x7fd4f6b0)
at /home/marco/soft/php-4.4.0/main/main.c:1751
#5  0x005777a3 in main (argc=2, argv=0x7fd4f828)
at /home/marco/soft/php-4.4.0/sapi/cli/php_cli.c:828


Segfault reproduced with php4-STABLE-200508300648 and php-4.4.0.

Reproduce code:
---
http://194.204.33.43/test.txt', 'r');
 $line = fread($fp, 1);
 unserialize($line);
 fclose($fp);

?>

Expected result:

no output

Actual result:
--
Segmentation fault





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


#34336 [Asn->Fbk]: ext/gd: imagerotate destroys transparency information

2005-09-02 Thread pajoye
 ID:   34336
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Assigned
+Status:   Feedback
 Bug Type: Feature/Change Request
 Operating System: *
 PHP Version:  5CVS, 4CVS (2005-08-31)
 Assigned To:  pajoye
 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


Try the newly added 4th argument:

imagerotate($rsr, $angle, $bg_color, $keeptransparency);

However, note that this is interpolated colors in the destination
images (rotated), meaning that if the original image has some
antialiased artifacts with the bgd color, you will notice them in the
rotated image (in your case, a white border), not much can be done
against that.

--Pierre




Previous Comments:


[2005-09-01 21:41:26] [EMAIL PROTECTED]

Description:

Imagerotate doesn't preserve transparency information.
Next image was used in example below:
http://img24.imageshack.us/img24/228/spritepaw8alpha2os.png


Reproduce code:
---


Expected result:

Rotated image with transparent background.

Actual result:
--
Rotated image with black background.





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


#32301 [Fbk->Opn]: PHP hangs during decompression

2005-09-02 Thread ralph at cs dot cf dot ac dot uk
 ID:   32301
 User updated by:  ralph at cs dot cf dot ac dot uk
 Reported By:  ralph at cs dot cf dot ac dot uk
-Status:   Feedback
+Status:   Open
 Bug Type: Zlib Related
 Operating System: MacOS X 10.3.x
 PHP Version:  5CVS-2005-03-30
 New Comment:

Hmm. there is something odd going on here.

This snapshot does solve the problem on MacOS X 10.4.2 for 
the test case reported.

However, the original source of the problem was when 
installing stuff with PEAR, and that STILL does NOT work.

E.g.  sudo pear install Image_Barcode
downloading Image_Barcode-1.0.4.tgz ...
Starting to download Image_Barcode-1.0.4.tgz (13,150 bytes)
.done: 13,150 bytes

Hangs, processor running flat out, until aborted with CTRL-
C.

Before, after a long discussion with the PEAR folks, they 
produced the test case reported here to show it was not a 
PEAR bug.

Unfortunately, the fix so far seems to fix the test case, 
but not the real problem to be addressed!


Previous Comments:


[2005-09-02 08:53:26] [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

And don't invent your own PHP versions. The version string in the bug
reports must start with a NUMBER..




[2005-03-30 15:45:59] ralph at cs dot cf dot ac dot uk

Have tried this with 
php5-200503301230

Bug is still present.



[2005-03-18 19:31:59] [EMAIL PROTECTED]

2nd try:

  http://snaps.php.net/php5-latest.tar.gz

(for your convinience I removed the url for the win32
binaries..*SIGH*)

There's nothing wrong with the snapshot, I checked it myself.





[2005-03-14 14:42:35] ralph at cs dot cf dot ac dot uk

Description:

Running the following compression / decompression code 
on MacOS X results in php hanging, and control never 
being retuyrned to the user.

One particular side effect is that doing
sudo pear upgrade-all
does not install the upgrades and hangs. However, this 
problem appears to be in php itself, not pear.

Reproduce code:
---


Expected result:

OK Done!

on completion.

Actual result:
--
Never returns.





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


#34260 [Asn->Csd]: Segfault with callbacks (array_map) + overloading

2005-09-02 Thread dmitry
 ID:   34260
 Updated by:   [EMAIL PROTECTED]
 Reported By:  etnu at etnu dot org
-Status:   Assigned
+Status:   Closed
 Bug Type: Scripting Engine problem
 Operating System: *
 PHP Version:  5CVS-2005-09-02
 Assigned To:  dmitry
 New Comment:

Fixed in CVS HEAD, PHP_5_1 and PHP_5_0.


Previous Comments:


[2005-09-02 07:25:57] [EMAIL PROTECTED]

Dmitry, can you check this out please?




[2005-08-28 01:11:06] [EMAIL PROTECTED]

Derick, in cases like this with nice and short example script which
clearly segfaults (I verified) you can propably come up with the
backtrace YOURSELF?

Here it is, for all the other lazy asses:

(gdb) bt
#0  0x5a2a8fcc in ?? ()
#1  0x083a55f1 in zend_call_function (fci=0xbfffd4a0,
fci_cache=0xbfffd4f0)
at /usr/src/php/php_5_1/Zend/zend_execute_API.c:885
#2  0x082de40e in zif_array_map (ht=2, return_value=0x89d4064,
return_value_ptr=0x0, this_ptr=0x0, 
return_value_used=1) at
/usr/src/php/php_5_1/ext/standard/array.c:4336
#3  0x083d739b in zend_do_fcall_common_helper_SPEC
(execute_data=0xbfffd6c0) at zend_vm_execute.h:184
#4  0x083db82f in ZEND_DO_FCALL_SPEC_CONST_HANDLER
(execute_data=0xbfffd6c0) at zend_vm_execute.h:1586
#5  0x083d707c in execute (op_array=0x89cf624) at zend_vm_execute.h:87
#6  0x083b09f1 in zend_execute_scripts (type=8, retval=0x0,
file_count=3)
at /usr/src/php/php_5_1/Zend/zend.c:1078
#7  0x0836f107 in php_execute_script (primary_file=0xbb00) at
/usr/src/php/php_5_1/main/main.c:1675
#8  0x08426636 in main (argc=2, argv=0xbbd4) at
/usr/src/php/php_5_1/sapi/cli/php_cli.c:1039

The crash happens for the 2nd call.




[2005-08-25 22:03:06] etnu at etnu dot org

Description:

A segfault occurs when using callbacks to functions that get triggered
via __call.

In the case of what's actually being called, the class is derived from
mysqli.

I haven't done extensive testing, but I was getting segfaults with both
array_map and array_filter. It seems to be a general callback-related
issue.

Dual Opteron
Kernel is SMP + 64bit
Configure:

./configure \
--with-pgsql \
--with-xmlrpc \
--with-apxs2=/usr/local/apache2/bin/apxs \
--with-mysql=/usr --with-mysqli=/usr/bin/mysql_config \
--prefix=/usr/local/apache2/php \
--with-config-file-path=/usr/local/apache2/php \
--enable-force-cgi-redirect \
--disable-magic-quotes \
--with-curl \
--with-gd --with-jpeg-dir=/usr/lib --with-png-dir=/usr/lib
--with-freetype-dir=/usr/lib --with-zlib-dir=/usr/lib


Reproduce code:
---


Expected result:

Not seg faulting.

Actual result:
--
Segfaulting.





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


#34311 [Asn]: unserialize() causes php to segfault

2005-09-02 Thread sniper
 ID:   34311
 Updated by:   [EMAIL PROTECTED]
 Reported By:  marco at storm dot ee
 Status:   Assigned
 Bug Type: Reproducible crash
 Operating System: *
 PHP Version:  5CVS, 4CVS (2005-08-31)
-Assigned To:  pollita
+Assigned To:  dmitry
 New Comment:

Dmitry, can you see if you can do anything about this?
(the serializer crashes with any char outside US-ASCII :)



Previous Comments:


[2005-08-31 16:41:08] [EMAIL PROTECTED]

Short reproducing script:

# php -r 'unserialize("å");'

(that's a with ring above it :)





[2005-08-31 14:54:34] [EMAIL PROTECTED]

0x08339834 in php_var_unserialize (rval=0xbfffce64, p=0xbfffce44,
max=0x89d8e4d "", var_hash=0xbfffce48) at :449
449 : No such file or directory.
in 
(gdb) bt
#0  0x08339834 in php_var_unserialize (rval=0xbfffce64, p=0xbfffce44,
max=0x89d8e4d "", var_hash=0xbfffce48) at :449
#1  0x0832d916 in zif_unserialize (ht=1, return_value=0x89d2ddc,
return_value_ptr=0x0, this_ptr=0x0, return_value_used=0)
at /usr/src/php/php_5_1/ext/standard/var.c:866
#2  0x083d9c7f in zend_do_fcall_common_helper_SPEC
(execute_data=0xbfffcfa0) at zend_vm_execute.h:184
#3  0x083de12e in ZEND_DO_FCALL_SPEC_CONST_HANDLER
(execute_data=0xbfffcfa0) at zend_vm_execute.h:1588
#4  0x083d9960 in execute (op_array=0x89d361c) at zend_vm_execute.h:87
#5  0x083b32c5 in zend_execute_scripts (type=8, retval=0x0,
file_count=3) at /usr/src/php/php_5_1/Zend/zend.c:1078
#6  0x083719a9 in php_execute_script (primary_file=0xb3e0) at
/usr/src/php/php_5_1/main/main.c:1682
#7  0x08428f36 in main (argc=2, argv=0xb4b4) at
/usr/src/php/php_5_1/sapi/cli/php_cli.c:1039




[2005-08-30 23:16:03] [EMAIL PROTECTED]

I don't get a segfault, but valgrind does give the following errors:
==22613==
==22613== Invalid read of size 1
==22613==at 0x8113A04: php_stream_url_wrap_http_ex
(http_fopen_wrapper.c:406)
==22613==by 0x81142F5: php_stream_url_wrap_http
(http_fopen_wrapper.c:569)
==22613==by 0x814836D: _php_stream_open_wrapper_ex
(streams.c:2696)
==22613==by 0x80DF0DC: php_if_fopen (file.c:1143)
==22613==by 0x81731B6: execute (zend_execute.c:1675)
==22613==by 0x8164CB8: zend_execute_scripts (zend.c:938)
==22613==by 0x813BA3C: php_execute_script (main.c:1743)
==22613==by 0x8177A86: main (php_cli.c:828)
==22613==  Address 0x1B9A50F7 is 1 bytes before a block of size 1024
alloc'd
==22613==at 0x1B9042A6: malloc (vg_replace_malloc.c:130)
==22613==by 0x8112FCC: php_stream_url_wrap_http_ex
(http_fopen_wrapper.c:390)
==22613==by 0x81142F5: php_stream_url_wrap_http
(http_fopen_wrapper.c:569)
==22613==by 0x814836D: _php_stream_open_wrapper_ex
(streams.c:2696)
==22613==by 0x80DF0DC: php_if_fopen (file.c:1143)
==22613==by 0x81731B6: execute (zend_execute.c:1675)
==22613==by 0x8164CB8: zend_execute_scripts (zend.c:938)
==22613==by 0x813BA3C: php_execute_script (main.c:1743)
==22613==by 0x8177A86: main (php_cli.c:828)





[2005-08-30 19:37:18] marco at storm dot ee

Description:

OS: Debian-AMD64, Linux 2.6.12.5
Configure line: configure --enable-debug --with-zlib

gdb:
Program terminated with signal 11, Segmentation fault.

#0  0x004ede39 in php_var_unserialize (rval=0x7fd4cc90,
p=0x7fd4cc58,
max=0x7bb831 "", var_hash=0x7fd4cc60)
at /home/marco/soft/php-4.4.0/ext/standard/var_unserializer.c:428
#1  0x004e5045 in zif_unserialize (ht=1, return_value=0x7b45e0,
this_ptr=0x0,
return_value_used=0) at
/home/marco/soft/php-4.4.0/ext/standard/var.c:716
#2  0x00570876 in execute (op_array=0x7b5200)
at /home/marco/soft/php-4.4.0/Zend/zend_execute.c:1672
#3  0x0055aa3d in zend_execute_scripts (type=8, retval=0x0,
file_count=3)
at /home/marco/soft/php-4.4.0/Zend/zend.c:938
#4  0x0051f878 in php_execute_script
(primary_file=0x7fd4f6b0)
at /home/marco/soft/php-4.4.0/main/main.c:1751
#5  0x005777a3 in main (argc=2, argv=0x7fd4f828)
at /home/marco/soft/php-4.4.0/sapi/cli/php_cli.c:828


Segfault reproduced with php4-STABLE-200508300648 and php-4.4.0.

Reproduce code:
---
http://194.204.33.43/test.txt', 'r');
 $line = fread($fp, 1);
 unserialize($line);
 fclose($fp);

?>

Expected result:

no output

Actual result:
--
Segmentation fault





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


#34126 [Asn->Csd]: function calls leak memory

2005-09-02 Thread dmitry
 ID:   34126
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Assigned
+Status:   Closed
 Bug Type: Scripting Engine problem
 Operating System: *
 PHP Version:  6CVS-2005-08-14 (CVS)
 Assigned To:  dmitry
 New Comment:

Thank you Nuno.

But this is already fixed in CVS HEAD.
Near the same patch.


Previous Comments:


[2005-08-14 16:51:12] [EMAIL PROTECTED]

Dmitry, check it out please.



[2005-08-14 13:52:57] [EMAIL PROTECTED]

Description:

Any simple function call leaks memory.

Patch: http://mega.ist.utl.pt/~ncpl/zend_unicode_leak.txt

Reproduce code:
---







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


#29719 [Opn->Fbk]: fgetcsv - double quotes issue

2005-09-02 Thread sniper
 ID:   29719
 Updated by:   [EMAIL PROTECTED]
 Reported By:  tjerk dot meesters at gmail dot com
-Status:   Open
+Status:   Feedback
 Bug Type: Filesystem function related
 Operating System: Linux-2.4
-PHP Version:  php-4.3.9RC2
+PHP Version:  4.3.9RC2
 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:


[2004-09-02 22:57:17] tjerk dot meesters at gmail dot com

I'd like to remind you that this issue is still not resolved. It gives
the wrong results when dealing with a line like below:

"""testing""";

The above is returned as:
testing"
(empty field)



[2004-08-20 02:40:06] t dot meesters at triptic dot nl

I meant that the problem is still there ;-) I've been browsing through
the code and finally came up with the following patch:

*** file.c.orig Fri Aug 20 02:30:27 2004
--- file.c  Fri Aug 20 02:30:37 2004
***
*** 2391,2399 
if ((p = memchr(p2, delimiter, (e - p2 {
p2 = s;
s = p + 1;
-   if (*p2 == enclosure) {
-   p2++;
-   }

/* copy data to buffer */
buf2 = erealloc(buf2, buf2_len + (p - p2) +
1);
--- 2391,2396 

After setting p2 to s it doesn't seem like a good idea to check if the
first character is a delimiter, since you might want to start a string
with two consecutive double quotes. By increasing p2, thus effectively
removing the first double quote, the trim_enclosed() function will
regard the remaining double quote as garbage and ignore it.

The patch has been tested and passes the above mentioned tests.



[2004-08-18 23:35:23] t dot meesters at triptic dot nl

Oops, I think the line wrapping caused an error in my initial input:
please note that test #3 should be:

"""test with inline double quotes""" (on one line)

Sorry for the inconvenience.



[2004-08-18 23:15:15] [EMAIL PROTECTED]

With latest CVS I get the correct output of: 
Array 
( 
[0] => test 
[1] => test spaced string 
[2] => test; with delimeter 
[3] => "test with inline 
double quotes" 
[4] => test 
with 
newlines 
[5] => "test 
with 
newlines and double quotes" 
) 
 



[2004-08-18 23:08:04] t dot meesters at triptic dot nl

Result is now:
Array
(
[0] => test
[1] => test spaced string
[2] => test; with delimeter
[3] => test with inline double quotes"
[4] => test
with
newlines
[5] => "test
with
newlines and double quotes"
)

Although the test with newlines and double quotes works fine now, the
problem still lies with test 3: the inline double quote.



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

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