#21171 [NEW]: config0.m4 instead of config.m4 in ext/zlib/ - phpize fails

2002-12-24 Thread tony2001
From: [EMAIL PROTECTED]
Operating system: Doesn't matetr
PHP version:  4.3.0RC4
PHP Bug Type: *General Issues
Bug description:  config0.m4 instead of config.m4 in ext/zlib/ - phpize fails

in ext/zlib file config.m4 is named config0.m4, so phpize fails.
renaming config0.m4 to config.m4 solves the problem.
-- 
Edit bug report at http://bugs.php.net/?id=21171&edit=1
-- 
Try a CVS snapshot: http://bugs.php.net/fix.php?id=21171&r=trysnapshot
Fixed in CVS:   http://bugs.php.net/fix.php?id=21171&r=fixedcvs
Fixed in release:   http://bugs.php.net/fix.php?id=21171&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=21171&r=needtrace
Try newer version:  http://bugs.php.net/fix.php?id=21171&r=oldversion
Not developer issue:http://bugs.php.net/fix.php?id=21171&r=support
Expected behavior:  http://bugs.php.net/fix.php?id=21171&r=notwrong
Not enough info:http://bugs.php.net/fix.php?id=21171&r=notenoughinfo
Submitted twice:http://bugs.php.net/fix.php?id=21171&r=submittedtwice
register_globals:   http://bugs.php.net/fix.php?id=21171&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=21171&r=php3
Daylight Savings:   http://bugs.php.net/fix.php?id=21171&r=dst
IIS Stability:  http://bugs.php.net/fix.php?id=21171&r=isapi




#21171 [Com]: config0.m4 instead of config.m4 in ext/zlib/ - phpize fails

2002-12-24 Thread tony2001
 ID:   21171
 Comment by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
 Status:   Bogus
 Bug Type: *General Issues
 Operating System: Doesn't matetr
 PHP Version:  4.3.0RC4
 New Comment:

hmm..
sounds rather strange, cause today I've found that I forgot to build
zlib at all and when I tried to phpize it - I've found this.
but "lot of other stuff in PHP" worked allright for several months.
I think this should be covered at least in README for this extension.


Previous Comments:


[2002-12-24 03:40:49] [EMAIL PROTECTED]

This is as it should be, just dont try to phpize the zlib extension as
a lot of other stuff in PHP depends on it anyway. Work is in progress
to disallow building zlib as an shared extension too.

Derick



[2002-12-24 03:35:58] [EMAIL PROTECTED]

in ext/zlib file config.m4 is named config0.m4, so phpize fails.
renaming config0.m4 to config.m4 solves the problem.




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




#26558 [Bgs->Ana]: High load of OCI-Calls crash on multiprocessor machine with Apache2

2003-12-10 Thread tony2001
 ID:   26558
 Updated by:   [EMAIL PROTECTED]
 Reported By:  k_becker at kat dot de
-Status:   Bogus
+Status:   Analyzed
 Bug Type: OCI8 related
 Operating System: Windows 2000 Adv. Server
 PHP Version:  4.3.4
 New Comment:

it seems to me, this bug appears due to the fact, that current
implementation of ext/oci8 doesn't use OCI_THREADED flag with
OCIInitialize();

Maxim tells about it here:
http://www.zend.com/lists/php-dev/200301/msg00213.html

OCI docs about OCI's thread safety are here:
http://docs.linux.cz/Oracle8/server/a58234/new_adva.htm#427495

I think, I can add this feature shortly.


Previous Comments:


[2003-12-10 09:14:02] [EMAIL PROTECTED]

Not PHP bug. (plus Apache2 + PHP in threaded env. is not really ready
for production anyway)




[2003-12-10 05:56:13] k_becker at kat dot de

I tried the "MaxThreadsPerChild=1" from Bug#19517. No crashes, but
Apache "... ran out of threads".

Then set 
MaxRequestsPerChild 10,
ThreadsPerChild 100
and tried using the explicit Oracle address string from TNSnames.ora.
This seems to work.

Then tried php4-win32-STABLE-latest.zip of 2003-dec-10: Same result.

I now have: Apache/1.3.28 (Win32) PHP/4.3.5-dev, OCI8 Revision:
1.183.2.7 on Windows 2000 adv. server build 2195 with
MaxRequestsPerChild 10, ThreadsPerChild 100.

Temporary solution seems to be using the TNS address string in
OCILogon("user", "pass",
"(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=127.0.0.1)(PORT=1521)))(CONNECT_DATA=(SID=xxx))")

So, problem seems to be in the Oracle/Oci8 name resolving in concurrent
OCILogon()'s from multiple Apache/PHP-threads.



[2003-12-09 06:09:35] [EMAIL PROTECTED]

Please try using this CVS snapshot:

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

Also, does this happen with anything else than oci8 ?




[2003-12-09 04:38:27] k_becker at kat dot de

Description:

Platform: 4-CPU machine, Apache 2.0.39..48, PHP 4.3.x, Win 2000 Adv.
server engl., OCI8, Oracle 8.1.7EE

When issuing multiple Oracle-requests at once, the Apache client thread
dies with protection fault (C005) without any further message from
PHP, Oracle or Apache.

Same code runs okay on one-CPU machine with same platform. Changing
Apache to 1.3.28 helped.

Could be a problem within the PHP for Apache2 parallelization on more
than one CPU.







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


#26558 [Asn->Csd]: High load of OCI-Calls crash on multiprocessor machine with Apache2

2003-12-16 Thread tony2001
 ID:   26558
 Updated by:   [EMAIL PROTECTED]
 Reported By:  k_becker at kat dot de
-Status:   Assigned
+Status:   Closed
 Bug Type: OCI8 related
 Operating System: Windows 2000 Adv. Server
 PHP Version:  4.3.4
 Assigned To:  tony2001
 New Comment:

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.

should be fixed in CVS.


Previous Comments:


[2003-12-10 09:19:56] [EMAIL PROTECTED]

it seems to me, this bug appears due to the fact, that current
implementation of ext/oci8 doesn't use OCI_THREADED flag with
OCIInitialize();

Maxim tells about it here:
http://www.zend.com/lists/php-dev/200301/msg00213.html

OCI docs about OCI's thread safety are here:
http://docs.linux.cz/Oracle8/server/a58234/new_adva.htm#427495

I think, I can add this feature shortly.



[2003-12-10 05:56:13] k_becker at kat dot de

I tried the "MaxThreadsPerChild=1" from Bug#19517. No crashes, but
Apache "... ran out of threads".

Then set 
MaxRequestsPerChild 10,
ThreadsPerChild 100
and tried using the explicit Oracle address string from TNSnames.ora.
This seems to work.

Then tried php4-win32-STABLE-latest.zip of 2003-dec-10: Same result.

I now have: Apache/1.3.28 (Win32) PHP/4.3.5-dev, OCI8 Revision:
1.183.2.7 on Windows 2000 adv. server build 2195 with
MaxRequestsPerChild 10, ThreadsPerChild 100.

Temporary solution seems to be using the TNS address string in
OCILogon("user", "pass",
"(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=127.0.0.1)(PORT=1521)))(CONNECT_DATA=(SID=xxx))")

So, problem seems to be in the Oracle/Oci8 name resolving in concurrent
OCILogon()'s from multiple Apache/PHP-threads.



[2003-12-09 04:38:27] k_becker at kat dot de

Description:

Platform: 4-CPU machine, Apache 2.0.39..48, PHP 4.3.x, Win 2000 Adv.
server engl., OCI8, Oracle 8.1.7EE

When issuing multiple Oracle-requests at once, the Apache client thread
dies with protection fault (C005) without any further message from
PHP, Oracle or Apache.

Same code runs okay on one-CPU machine with same platform. Changing
Apache to 1.3.28 helped.

Could be a problem within the PHP for Apache2 parallelization on more
than one CPU.







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


#26133 [Ana->Csd]: OCIDescriptorFree segfault PHP

2003-12-16 Thread tony2001
 ID:   26133
 Updated by:   [EMAIL PROTECTED]
 Reported By:  msanmartin at seamus dot es
-Status:   Analyzed
+Status:   Closed
 Bug Type: OCI8 related
 Operating System: Linux
 PHP Version:  4CVS, 5CVS
 New Comment:

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.




Previous Comments:


[2003-12-13 13:57:40] agarcia at at4 dot net

Just a wordaround until this bug gets fixed.

Use rowidtochar(rowid) to avoid using ocinewdescriptor.





[2003-12-08 11:16:01] tony2001 at phpclub dot net

if you replace this:
$db_log_rowid = OCINewDescriptor($db_log,OCI_D_ROWID);

with that:
$db_log_rowid = OCINewDescriptor($db_log,OCI_D_LOB);

you'll get another one segfault, but this one is initiated by
OciExecute();

isn't it an OCI bug?
it seems, that Oracle allocates memory for descriptor, but can't
initialize while executing the query and should return an error in this
case.



[2003-12-08 05:55:28] [EMAIL PROTECTED]

no need to allocate a descriptor for that.
 
see:






[2003-11-05 04:08:07] msanmartin at seamus dot es

Description:

If I call OCINewDescriptor for create a OCI_D_ROWID
when I free this descriptor or php free at the 
end it crash.
It happens in Oracle  9.2.0.1.0 
In Oracle 9.0.1.0.0 the code works.

I make a program in C that makes similar calls to
OCI8 but it works well.

The crash is in the call to OCIDescriptorFree.

I reproduce this in php4-200311050830 php-4.3.2 php-4.3.4
In php-4.2.2 the code works.


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


Actual result:
--
$ gdb /usr/local/src/php-4.3.4/sapi/cli/php 
GNU gdb 5.3
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-slackware-linux"...
(gdb) set args x2.php 
(gdb) run
Starting program: /usr/local/src/php-4.3.4/sapi/cli/php x2.php 
[New Thread 16384 (LWP 11411)]
end
** Internal heap ERROR 17112 addr=0x81d4278 *

* Dump of memory around addr 0x81d4278: 
81D4070      []
81D4080      []
Repeat 30 times
81D4270   8022 081D405C  ["[EMAIL PROTECTED]
81D4280 40921CBD 000A15CD D701 000D009F  [EMAIL PROTECTED]
81D4290 00DA2501 0059 8032 081D4278  [.%..Y...2...xB..]
81D42A0 408FAAA0 000A15CD    [EMAIL PROTECTED]
81D42B0      []
81D42C0   8052 081D4298  [RB..]
81D42D0 408FAAA0 000A15CD 081D42A8 0005  [EMAIL PROTECTED]
81D42E0  4000 4040   [EMAIL PROTECTED]@@]
81D42F0      []
81D4300 0010 402B29E0 402B2A30 081C29D8  [.)[EMAIL PROTECTED]@.)..]
81D4310   8032 081D42C8  [2B..]
81D4320 408FAAA0 000A15CD    [EMAIL PROTECTED]
81D4330      []
81D4340   8052 081D4318  [RC..]
81D4350 408FAAA0 000A15CD 081D4328 0005  [EMAIL PROTECTED](C..]
81D4360  4000 4040 402B2AE0  [EMAIL PROTECTED]@@[EMAIL PROTECTED]
81D4370 402B2B20     [ [EMAIL PROTECTED]
81D4380 0014 402B29E0 402B2A30 081C29D8  [.)[EMAIL PROTECTED]@.)..]
81D4390   8032 081D4348  [2...HC..]
81D43A0 408FAAA0 000A15CD    [EMAIL PROTECTED]
81D43B0      []
81D43C0   8052 081D4398  [RC..]
81D43D0 408FAAA0 000A15CD 081D43A8 0005  [EMAIL PROTECTED]
81D43E0  4000 4040 402B2A70  [EMAIL PROTECTED]@@[EMAIL PROTECTED]
81D43F0 402B2AA0     [EMAIL PROTECTED]
81D4400 005C 402B29E0 402B2A30 081C29D8  [\)[EMAIL PROTECTED]@.)..]
81D4410   8

#9496 [Csd->Ver]: Mixing non persistant and persistant connection makes all connexions persistant

2003-12-19 Thread tony2001
 ID:   9496
 Updated by:   [EMAIL PROTECTED]
 Reported By:  jean-francois dot gosset at telintrans dot fr
-Status:   Closed
+Status:   Verified
 Bug Type: OCI8 related
 Operating System: linux red hat 6.2
 PHP Version:  4.0.4pl1
 New Comment:

Could you, please, try it with latest CVS snapshots of PHP5 & PHP4?
This behaviour was changed in PHP5 recently.


Previous Comments:


[2003-12-18 17:14:41] kamil at okac dot org

The behaviour is correct for the case when you call OCILogon('u1','p1')
and OCIPLogon('u1','p1') (with the same user), but incorrect when you
call OCILogon('u1','p1') and OCIPlogon('u2','p2'). The latter case
creates two sessions (that's correct - can't be shared, because two
different users are logging in), but both sessions are made
persistent.
This happens even if OCIPlogon and OCILogon are not called within one
script but handled by the same process.

Maybe the problem is in the reusing of persistent server connections
(where usernames are not involved).



[2002-04-13 08:18:07] [EMAIL PROTECTED]

i still cannot see any problem. you approach would consume _more_
resourcs on the oracle server. anyhow this is not a bug.




[2001-06-15 03:53:55] jean-francois dot gosset at telintrans dot fr


I think this behaviour is confusing.

One can have the needs to mix persistant and non persistant connexion
on the same database. In my case, I want to validate an account with a
personal username and after use a generic account. The first one must
not be persistant because we would have too much connexions open.





[2001-05-04 10:44:07] [EMAIL PROTECTED]

OCIPlogon() will do the same as OCILogon() but mark the sever and
session handle as persistent, which means that PHP won't close them on
script-end. if your script does a OCILogon("s","t") and later a
OCIPLogon("s","t") _no_ new server or session handle will be created
but instead the existing ones will be marked persistent.

this is intended behaviour - why would we want to change it?




[2001-02-28 08:33:16] jean-francois dot gosset at telintrans dot fr

With the following test (test_oci8.php) both connexions (USER_1 and
USER_2) are persistant.

Notes :

1. We can see that connexions are persistant with the following SQL
command :

  select username, status, logon_time from v$session where
username='USER_1' or username='USER_2';
  
2. We can use the following workaround : use a different database name
for USER_1 and USER_2 (who acces the same real database).

3. If we invert the order of connexions (USER_2 before USER_1) and use
OCInlogon for USER_1, only USER_2 has persistant connexions but the
number of connexions of USER_2 increase until to reach the maximum
limit (ORA-00604 error).


---
test_oci8.php
---

OCI8 bug test


<%

$user = "USER_1";
$password = "pwd1";
$database = "TEST";

{
// should be non persistent 
$connexion = OCIlogon (
$user,
$password,
$database);

if (!$connexion)
{
trigger_error (
"Erreur OCIlogon $user / $database",
E_USER_ERROR);
}
else
{
echo "Connexion 1 OK";
}

OCIlogoff ($connexion);
}

{
$user = "USER_2";
$password = "pwd2";
$database = "TEST";

// If we use a different databasename (for the same real
database) we don't have the problem
// $database = "TEST2";

$connexion = OCIplogon (
$user,
$password,
$database);

if (!$connexion)
{
trigger_error (
"Erreur OCIplogon $user / $database",
E_USER_ERROR);
}
else
{
echo "Connexion 2 OK";
}

OCIlogoff ($connexion);
}


%>


---






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


#26393 [Opn->Ver]: Segfault during request shutdown in _oci_close_session() (oci8.c:2443)

2003-12-19 Thread tony2001
 ID:   26393
 Updated by:   [EMAIL PROTECTED]
 Reported By:  troy dot tinnes at motorola dot com
-Status:   Open
+Status:   Verified
 Bug Type: OCI8 related
 Operating System: Solaris 2.8
 PHP Version:  4.3.4
 New Comment:

yes, there is some troubles with thread safety in PHP_4_3 branch.
I'll ask Harald to port his changes from HEAD one more time.
could you, please, try latest PHP5 snapshot? it should be fixed there.


Previous Comments:


[2003-12-19 11:03:08] troy dot tinnes at motorola dot com

We are still having problems with this - from my point of view the
snapshots have not fixed the problem. 

Here is our backtrace after loading one of the recent snapshots.

Program received signal SIGSEGV, Segmentation fault.
0xff0331f0 in strlen () from /usr/lib/libc.so.1
(gdb) bt
#0  0xff0331f0 in strlen () from /usr/lib/libc.so.1
#1  0xfe1e4434 in _oci_close_session (session=0x313fd0)
at
/opt/web/apache_php/source/php4-200312152030/ext/oci8/oci8.c:2443
#2  0xfe1df7c4 in _oci_session_list_dtor (rsrc=0x201348)
at
/opt/web/apache_php/source/php4-200312152030/ext/oci8/oci8.c:935
#3  0xfe35f1b4 in list_entry_destructor (ptr=0x201348)
at
/opt/web/apache_php/source/php4-200312152030/Zend/zend_list.c:177
#4  0xfe35c084 in zend_hash_apply_deleter (ht=0xfe3d1cac, p=0x201cc8)
at
/opt/web/apache_php/source/php4-200312152030/Zend/zend_hash.c:598
#5  0xfe35c424 in zend_hash_graceful_reverse_destroy (ht=0xfe3d1cac)
at
/opt/web/apache_php/source/php4-200312152030/Zend/zend_hash.c:664
#6  0xfe35f3e4 in zend_destroy_rsrc_list (ht=0xfe3d1cac)
at
/opt/web/apache_php/source/php4-200312152030/Zend/zend_list.c:233
#7  0xfe341964 in shutdown_executor ()
at
/opt/web/apache_php/source/php4-200312152030/Zend/zend_execute_API.c:213
#8  0xfe352a84 in zend_deactivate ()
at /opt/web/apache_php/source/php4-200312152030/Zend/zend.c:666
#9  0xfe2f8978 in php_request_shutdown (dummy=0x0)
at /opt/web/apache_php/source/php4-200312152030/main/main.c:995
#10 0xfe374f08 in php_apache_request_dtor (r=0x187d80)
at
/opt/web/apache_php/source/php4-200312152030/sapi/apache2handler/sapi_apache2.c:445
#11 0xfe375320 in php_handler (r=0x187d80)
---Type  to continue, or q  to quit---
at
/opt/web/apache_php/source/php4-200312152030/sapi/apache2handler/sapi_apache2.c:541
#12 0x0004a37c in ap_run_handler (r=0x187d80) at config.c:195 #13
0x0004a950 in ap_invoke_handler (r=0x187d80) at config.c:401 #14
0x00037d60 in ap_process_request (r=0x187d80) at http_request.c:288 #15
0x00033274 in ap_process_http_connection (c=0x1691d0) at
http_core.c:293 #16 0x00055740 in ap_run_process_connection
(c=0x1691d0) at connection.c:85 #17 0x00048b78 in child_main
(child_num_arg=1470816) at prefork.c:694 #18 0x00048d70 in make_child
(s=0x9bb80, slot=0) at prefork.c:734 #19 0x00048dfc in startup_children
(number_to_start=4) at prefork.c:806 #20 0x0004962c in ap_mpm_run
(_pconf=0x1, plog=0xd1558, s=0x9bb80)
at prefork.c:1022
#21 0x0004f23c in main (argc=2, argv=0xffbefd14) at main.c:660



[2003-12-02 00:37:10] troy dot tinnes at motorola dot com

Can we perhaps keep this one open and close the other one? Looks like
that other person fixed their problem using persistent connections and
probably not as motivated to work with you guys as I am  This is a
critical bug for me and holding up my development at the moment!



[2003-11-27 01:09:06] [EMAIL PROTECTED]

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

Thank you for your interest in PHP.

Exactly same as bug #24531



[2003-11-27 00:28:04] [EMAIL PROTECTED]

User reported that patch produced exact same backtrace as before.
(PLEASE don't add that same bt anymore..)




[2003-11-25 14:18:22] [EMAIL PROTECTED]

Oops..I meant the Open reports.. :)
See bug #24531 which has some patch in it.
Try the patch..




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

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


#26738 [Opn]: PHP-OCI binding error

2004-01-12 Thread tony2001
 ID:   26738
 Updated by:   [EMAIL PROTECTED]
 Reported By:  mbaranidharan at yahoo dot com
 Status:   Open
 Bug Type: OCI8 related
 Operating System: *
 PHP Version:  4.3.4
 New Comment:

Can you tell us what error exactly do you get?
Are there any error messages? Currently I can't understand what are you
talking about, sorry.


Previous Comments:


[2004-01-04 23:21:17] mbaranidharan at yahoo dot com

Iam trying to call a package in oracle 9i db which returns me out
parameters of type table.When i try to bind the out parameter and
execute iam getting error. This error occured bcoz table type in oracle
again internally an array which php is not able to identify.I get the
same error with both ORA and OCI.



[2004-01-02 11:00:55] [EMAIL PROTECTED]

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

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

Thank you for your interest in PHP.






[2003-12-29 04:56:56] mbaranidharan at yahoo dot com

Description:

Trying to call a package in oracle which will return a parameter of
type table. When i try calling the procedure from PHP using OCI iam
getting wrong types or parameters.

Reproduce code:
---
$sql="declare var1 xxx.tbl_date;var2 xxx.tbl_varchar;";
$sql=$sql."begin xxx(3,:var1,:var2,:var3);end;";
$conn   = OCILogon("usr","pwd","servername");
$stmt   = OCIParse($conn,$sql);
OCIBindByname($stmt,'var1',$var1);
OCIBindByname($stmt,'var2',$var2);
OCIBindByname($stmt,'var3',$var3);
$rs = OCIExecute($stmt);

Expected result:

The result should be stored in the recordset which later can be
iterated and get the values from each array variable var1,2 and 3.






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


#26738 [Opn->Bgs]: PHP-OCI binding error

2004-01-13 Thread tony2001
 ID:   26738
 Updated by:   [EMAIL PROTECTED]
 Reported By:  mbaranidharan at yahoo dot com
-Status:   Open
+Status:   Bogus
 Bug Type: OCI8 related
 Operating System: *
 PHP Version:  4.3.4
 New Comment:

First, you need to allocate new descriptor with ocinewdescriptor().
Your stored proc will return cursor, using this descriptor. After this
your should fetch data from this cursor, as you usually do with query
results.
And second:
after these two lines your variable contains only "Begin etc.". Use
$sql .= in second line.
---
#1 sql = "declare o_EmpNo Employee_pkg.tblEmpNo;o_EName
Employee_pkg.tblEName;o_Job Employee_pkg.tblJob;"; 
#2 $sql = "Begin
Employee_pkg.EmployeeSearch('e',:o_EmpNo,:o_EName,:o_Job);End;";
---

This doesn't look like a bug, bogusifying it..


Previous Comments:


[2004-01-12 23:54:28] mbaranidharan at yahoo dot com

Below i have given the package and package body created in oracle
database.
*
CREATE PACKAGE Employee_Pkg 
AS 
TYPE tblEmpNo IS TABLE OF NUMBER(4) INDEX BY BINARY_INTEGER; 
TYPE tblEName IS TABLE OF VARCHAR2(10) INDEX BY BINARY_INTEGER; 
TYPE tblJob IS TABLE OF VARCHAR2(9) INDEX BY BINARY_INTEGER; 

PROCEDURE EmployeeSearch 
   (i_EName IN VARCHAR2, 
o_EmpNo OUT tblEmpNo, 
o_EName OUT tblEName, 
o_Job OUT tblJob); 
END Employee_Pkg;
/
CREATE PACKAGE BODY Employee_Pkg 
AS 
PROCEDURE EmployeeSearch 
   (i_EName IN VARCHAR2, 
o_EmpNo OUT tblEmpNo, 
o_EName OUT tblEName, 
o_Job OUT tblJob) 
IS
CURSOR cur_employee (curName VARCHAR2) IS 
  SELECT empno, 
 ename, 
 job 
  FROM emp 
  WHERE UPPER(ename) LIKE '%' || UPPER(curName) || '%' 
  ORDER BY ename; 
  RecordCount NUMBER DEFAULT 0;
BEGIN 
  FOR curRecEmployee IN cur_employee(i_EName) LOOP 
 RecordCount:= RecordCount + 1; 
 o_EmpNo(RecordCount):= curRecEmployee.empno; 
 o_EName(RecordCount):= curRecEmployee.ename; 
 o_Job(RecordCount):= curRecEmployee.job; 
  END LOOP; 
   END EmployeeSearch; 
END Employee_Pkg;
/
*
Below is my sql block calling the package

SQL="declare 
o_EmpNo Employee_pkg.tblEmpNo; 
o_EName Employee_pkg.tblEName; 
o_Job Employee_pkg.tblJob; 
Begin Employee_pkg.EmployeeSearch('e',:o_EmpNo,:o_EName,:o_Job);
End;"
when i call this package from php using OCI i should get the results as
below
o_EmpNo o_EName o_job
7499ALLEN   SALESMAN
7698BLAKE   MANAGER
7900JAMES   CLERK
7566JONES   MANAGER
7934MILLER  CLERK
7844TURNER  SALESMAN

but iam getting error msg as
Warning: ociexecute(): OCIStmtExecute: ORA-06550: line 1, column 7:
PLS-00306: wrong number or types of arguments in call to
'EMPLOYEESEARCH' ORA-06550: line 1, column 7: PLS-00306: wrong number
or types of arguments in call to 'EMPLOYEESEARCH' ORA-06550: line 1,
column 7: PLS-00306: wrong number or types of arguments in call to
'EMPLOYEESEARCH' ORA-06550: line 1, column 7: PL/SQL: Statement ignored
in c:\apache group\apache\htdocs\

here is the code that i executed

$sql = "declare o_EmpNo Employee_pkg.tblEmpNo;o_EName
Employee_pkg.tblEName;o_Job Employee_pkg.tblJob;"; 
$sql = "Begin
Employee_pkg.EmployeeSearch('e',:o_EmpNo,:o_EName,:o_Job);End;";

$conn   = OCILogon("scott","tiger");
$stmt   = OCIParse($conn,$sql);

   OCIBindByname($stmt,':o_Empno',$o_array1);
   OCIBindByname($stmt,':o_EName',$o_timestamp);
   OCIBindByname($stmt,':o_Job',$o_array2);
   OCIExecute($stmt);
  
   OCILogoff($conn);



[2004-01-12 19:27:36] [EMAIL PROTECTED]

Can you tell us what error exactly do you get?
Are there any error messages? Currently I can't understand what are you
talking about, sorry.



[2004-01-04 23:21:17] mbaranidharan at yahoo dot com

Iam trying to call a package in oracle 9i db which returns me out
parameters of type table.When i try to bind the out parameter and
execute iam getting error. This error occured bcoz table type in oracle
again internally an array which php is not able to identify.I get the
same error with both ORA and OCI.



[2004-01-02 11:00:55] [EMAIL PROTECTED]

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

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

Thank you for your interest in PHP.






[2003-12-29 04:56:56] mbaranidharan at yahoo dot com

Description:

Trying to call a pac

#26892 [Opn->Ana]: ocinewcollection fails with Oracle 9.2

2004-01-13 Thread tony2001
 ID:   26892
 Updated by:   [EMAIL PROTECTED]
 Reported By:  tomy at envox dot hr
-Status:   Open
+Status:   Analyzed
 Bug Type: OCI8 related
 Operating System: Suse 8.2
 PHP Version:  4CVS-2004-01-13 (stable)
 New Comment:

Please, try PHP5 latest snapshots and check if it works with them.


Previous Comments:


[2004-01-13 11:24:47] tomy at envox dot hr

Did some trial/error testing with earlier PHP versions and
found out that this problem does not exist with version 4.3.1, appears
in version 4.3.2 and exists ever since...
It is even possible to bypass it by copying 4.3.1 oci extension source
to latest CVS snapshot and then the problem does not exist anymore.
Also it seems, although I cannot confirm that with 100% certainity,
that it only exists if 9.2 client is used by php. It seems that 8.0
client is not affected.
Hope this helps.



[2004-01-13 06:42:04] tomy at envox dot hr

Forgot to mention my oci data from phpinfo...:
OCI8 Support  enabled  
Revision  $Revision: 1.183.2.7 $  
Oracle Version  9.2  
Compile-time ORACLE_HOME  /opt/oracle/product/9ir2  
Libraries Used  no value



[2004-01-13 06:37:08] tomy at envox dot hr

Description:

ocinewcollection returns false and produces a warning, output with oci
debug enabled follows in actual result.

I have checked in source and using oci_debug that OCIInitialize is
called using OCI_DEFAULT | OCI_OBJECT so I do not understand why this
error happens.

PHP is compiled using this configure:
"
'./configure' '--enable-sigchild' '--disable-static'
'--enable-track-vars' '--enable-trans-sid' '--enable-sockets'
'--with-mysql' '--with-xml' '--disable-rpath' '--disable-pic'
'--disable-posix' '--with-zlib' '--without-pear' '--without-aspell'
'--disable-dbase' '--disable-dba' '--without-mhash' '--without-gmp'
'--with-gnu-ld' '--disable-bcmath' '--without-cdb' '--without-db3'
'--without-db2' '--without-gdbm' '--without-ndbm' '--without-dbm'
'--without-dom' '--enable-mbstring' '--enable-mbstr-enc-trans'
'--with-recode' '--with-gd' '--enable-shmop' '--enable-sysvsem'
'--with-xmlrpc' '--with-oci8' '--with-mcrypt' '--with-apxs' "

LOCAL_ID_ARRAY is defined as:
"
CREATE OR REPLACE TYPE local_id_array AS TABLE OF NUMBER(11);
"

Reproduce code:
---
$_db_tns =
"(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=192.168.3.41)(PORT=1521)))(CONNECT_DATA=(SID=pirana)(SERVER=DEDICATED)))";
$_db_user = "system";
$_db_pwd = "pirana";


   ociinternaldebug(1);
   $db = ocinlogon($_db_user, $_db_pwd, $_db_tns);
   $arr = ocinewcollection($db, 'LOCAL_ID_ARRAY');
   if ($arr === false) echo "Collection failed";


Expected result:

I expect only oci debug data to be written.

Actual result:
--
$arr should be OCI-Collection however it is false.

Actual output is:
"
OCIDebug: _oci_open_server new conn=0
dname=(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=192.168.3.41)(PORT=1521)))(CONNECT_DATA=(SID=pirana)(SERVER=DEDICATED)))
OCIDebug: _oci_open_session new sess=5 user=system
OCIDebug: oci_do_connect: id=6

Warning: ocinewcollection(): OCITypeByName: ORA-21301: not initialized
in object mode in /srv/www/htdocs/envox/info2.php on line 18
Collection failed
OCIDebug: START php_rshutdown_oci
OCIDebug: END php_rshutdown_oci
OCIDebug: START _oci_coll_list_dtor: 7
OCIDebug: START _oci_conn_list_dtor: id=6
OCIDebug: nothing to do..
OCIDebug: START _oci_close_session: logging-off sess=5
OCIDebug: END _oci_conn_list_dtor: id=6
OCIDebug: END _oci_coll_list_dtor: 7
OCIDebug: START _oci_close_server: detaching conn=4
dbname=(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=192.168.3.41)(PORT=1521)))(CONNECT_DATA=(SID=pirana)(SERVER=DEDICATED)))
"





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


#26829 [Fbk->Ver]: Killed Oracle Sessions openned with OCIPLogon()

2004-01-13 Thread tony2001
 ID:   26829
 Updated by:   [EMAIL PROTECTED]
 Reported By:  david dot gaia dot kano at dartmouth dot edu
-Status:   Feedback
+Status:   Verified
 Bug Type: OCI8 related
 Operating System: Compaq Unix
 PHP Version:  4.3.4


Previous Comments:


[2004-01-07 20:14:23] [EMAIL PROTECTED]

Please try using this CVS snapshot:

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

AFAICT, the function does check if persistent connection is still alive
(using oci_ping())..but did you mean the connection is killed while the
script is being run or what?




[2004-01-07 11:36:45] david dot gaia dot kano at dartmouth dot edu

Description:

Here at Dartmouth our DBA team has a policy of killing any Oracle
session that has been connected for longer than 24 hours. Hence the
persistant connections created by the PHP OCIPLogon() call get killed
once a day. We don't really want to restart our apache server once a
day, so it would be great if OCIPLogon() would check to see that a
previously created persistant connection is still good somehow and if
not, create a new connection.

I noticed quite a few bugs along these lines, but they have all been
closed. I don't know if that is because this bug was fixed or because
the submitters have continued to restart their servers after every
database restart or killed connection.

If this is not going to be fixed, I guess we would have to write our
own application level code to check the connections from ociplogon()
and if it is bad, use OCILogon() instead for that request and issue a
apache_child_terminate() call so that eventually all the children with
bad oracle sessions would be restarted...

Reproduce code:
---
$con = OCIPLogon("user", "password", "tns_db_name");
// at this point all looks good still... $con != false
// but if this session was killed then any use of $con 
// results in one error or another.






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


#26892 [Opn]: ocinewcollection fails with Oracle 9.2

2004-01-14 Thread tony2001
 ID:   26892
 Updated by:   [EMAIL PROTECTED]
 Reported By:  tomy at envox dot hr
 Status:   Open
 Bug Type: OCI8 related
 Operating System: Suse 8.2
 PHP Version:  4CVS-2004-01-13 (stable)
 New Comment:

PHP_OCI8_HAVE_COLLECTIONS should be defined in ./configure execution
process. you should not change its value manually.
./configure checks if there are appropriate functions in oracle client
and decides if there is possibility to turn on collection support.
so, check ./config.log, plz.
it seems, that there is no OCICollAssign function in your OCI version.
that's rather strange, 'cause I've tested it successfully with Oracle
9.2.0.1


Previous Comments:


[2004-01-14 04:31:19] tomy at envox dot hr

Downloaded http://snaps.php.net/php5-latest.tar.gz
and compiled.
Had to install mysql-develop packages and newer libxml2 packages (I had
to "borrow these from Suse 9.0 since there are no libxml2-2.5.10 for
Suse 8.2, only 2.5.3, hope this is ok).

After compiling and installing I got an error saying that there is no
function named ocinewcollection.
Revised the source in ext/oci8/oci8.c and noticed that
PHP_OCI8_HAVE_COLLECTIONS is note defined, so I defined it and compiled
again.

After that I got same error from the original bug report in slightly
different from. The result of ocinewcollection is still false :(.
Output follows
"
OCIDebug: _oci_open_server new conn=0
dname=(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=192.168.3.41)(PORT=1521)))(CONNECT_DATA=(SID=pirana)(SERVER=DEDICATED)))
OCIDebug: _oci_open_session new sess=3 user=system
OCIDebug: oci_do_connect: id=4

Warning: ocinewcollection() [function.ocinewcollection]: OCITypeByName:
ORA-21301: not initialized in object mode in
/srv/www/htdocs/envox/info2.php on line 14
Collection failed
OCIDebug: START php_rshutdown_oci
OCIDebug: END php_rshutdown_oci
OCIDebug: START _oci_coll_list_dtor: 5
OCIDebug: END _oci_coll_list_dtor: 5
OCIDebug: START _oci_conn_list_dtor: id=4
OCIDebug: nothing to do..
OCIDebug: START _oci_close_session: logging-off sess=3
OCIDebug: END _oci_conn_list_dtor: id=4
"

So, yes, you can place this bug into 5CVS also .
I can only mention once more that the last version that worked is
4.3.1. 4.3.2 introduced this bug and it exists ever since.



[2004-01-13 13:50:07] [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





[2004-01-13 13:44:58] [EMAIL PROTECTED]

Please, try PHP5 latest snapshots and check if it works with them.



[2004-01-13 11:24:47] tomy at envox dot hr

Did some trial/error testing with earlier PHP versions and
found out that this problem does not exist with version 4.3.1, appears
in version 4.3.2 and exists ever since...
It is even possible to bypass it by copying 4.3.1 oci extension source
to latest CVS snapshot and then the problem does not exist anymore.
Also it seems, although I cannot confirm that with 100% certainity,
that it only exists if 9.2 client is used by php. It seems that 8.0
client is not affected.
Hope this helps.



[2004-01-13 06:42:04] tomy at envox dot hr

Forgot to mention my oci data from phpinfo...:
OCI8 Support  enabled  
Revision  $Revision: 1.183.2.7 $  
Oracle Version  9.2  
Compile-time ORACLE_HOME  /opt/oracle/product/9ir2  
Libraries Used  no value



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

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


#26393 [Opn->Asn]: Segfault during request shutdown in _oci_close_session() (oci8.c:2443)

2004-01-15 Thread tony2001
 ID:   26393
 Updated by:   [EMAIL PROTECTED]
 Reported By:  troy dot tinnes at motorola dot com
-Status:   Open
+Status:   Assigned
 Bug Type: OCI8 related
 Operating System: Solaris 2.8
 PHP Version:  4.3.4
-Assigned To:  
+Assigned To:  tony2001
 New Comment:

ok, I'll try to make it work with 4.3.x soon.


Previous Comments:


[2004-01-15 07:25:28] troy dot tinnes at motorola dot com

With the testing so far - PHP 5 installation appears to fix the
problem.



[2004-01-15 01:29:31] [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





[2003-12-19 12:18:33] [EMAIL PROTECTED]

yes, there is some troubles with thread safety in PHP_4_3 branch.
I'll ask Harald to port his changes from HEAD one more time.
could you, please, try latest PHP5 snapshot? it should be fixed there.



[2003-11-27 00:28:04] [EMAIL PROTECTED]

User reported that patch produced exact same backtrace as before.
(PLEASE don't add that same bt anymore..)




[2003-11-25 14:18:22] [EMAIL PROTECTED]

Oops..I meant the Open reports.. :)
See bug #24531 which has some patch in it.
Try the patch..




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

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


#26738 [Opn->Fbk]: PHP-OCI binding error

2004-01-15 Thread tony2001
 ID:   26738
 Updated by:   [EMAIL PROTECTED]
 Reported By:  mbaranidharan at yahoo dot com
-Status:   Open
+Status:   Feedback
 Bug Type: OCI8 related
 Operating System: *
 PHP Version:  4.3.4
 New Comment:

Aha, I got your point at least. It seems, that you need to use
ocinewcollection() and other ocicoll*() functions to work with these
user-defined types.


Previous Comments:


[2004-01-13 23:16:56] mbaranidharan at yahoo dot com

my procedure does not return any cursor here it will return a pl/sql
table. Its using cursor to fetch data and populate into pl/sql table.
Basically the error come when i try to bind an array to variable. Look
at my procedure below
PROCEDURE EmployeeSearch 
   (i_EName IN VARCHAR2, 
o_EmpNo OUT tblEmpNo, 
o_EName OUT tblEName, 
o_Job OUT tblJob); 
END Employee_Pkg;
it takes in one parameter and returns 3 out parameters which is of
table type not cursor.



[2004-01-13 13:20:02] [EMAIL PROTECTED]

First, you need to allocate new descriptor with ocinewdescriptor().
Your stored proc will return cursor, using this descriptor. After this
your should fetch data from this cursor, as you usually do with query
results.
And second:
after these two lines your variable contains only "Begin etc.". Use
$sql .= in second line.
---
#1 sql = "declare o_EmpNo Employee_pkg.tblEmpNo;o_EName
Employee_pkg.tblEName;o_Job Employee_pkg.tblJob;"; 
#2 $sql = "Begin
Employee_pkg.EmployeeSearch('e',:o_EmpNo,:o_EName,:o_Job);End;";
---

This doesn't look like a bug, bogusifying it..



[2004-01-12 23:54:28] mbaranidharan at yahoo dot com

Below i have given the package and package body created in oracle
database.
*
CREATE PACKAGE Employee_Pkg 
AS 
TYPE tblEmpNo IS TABLE OF NUMBER(4) INDEX BY BINARY_INTEGER; 
TYPE tblEName IS TABLE OF VARCHAR2(10) INDEX BY BINARY_INTEGER; 
TYPE tblJob IS TABLE OF VARCHAR2(9) INDEX BY BINARY_INTEGER; 

PROCEDURE EmployeeSearch 
   (i_EName IN VARCHAR2, 
o_EmpNo OUT tblEmpNo, 
o_EName OUT tblEName, 
o_Job OUT tblJob); 
END Employee_Pkg;
/
CREATE PACKAGE BODY Employee_Pkg 
AS 
PROCEDURE EmployeeSearch 
   (i_EName IN VARCHAR2, 
o_EmpNo OUT tblEmpNo, 
o_EName OUT tblEName, 
o_Job OUT tblJob) 
IS
CURSOR cur_employee (curName VARCHAR2) IS 
  SELECT empno, 
 ename, 
 job 
  FROM emp 
  WHERE UPPER(ename) LIKE '%' || UPPER(curName) || '%' 
  ORDER BY ename; 
  RecordCount NUMBER DEFAULT 0;
BEGIN 
  FOR curRecEmployee IN cur_employee(i_EName) LOOP 
 RecordCount:= RecordCount + 1; 
 o_EmpNo(RecordCount):= curRecEmployee.empno; 
 o_EName(RecordCount):= curRecEmployee.ename; 
 o_Job(RecordCount):= curRecEmployee.job; 
  END LOOP; 
   END EmployeeSearch; 
END Employee_Pkg;
/
*
Below is my sql block calling the package

SQL="declare 
o_EmpNo Employee_pkg.tblEmpNo; 
o_EName Employee_pkg.tblEName; 
o_Job Employee_pkg.tblJob; 
Begin Employee_pkg.EmployeeSearch('e',:o_EmpNo,:o_EName,:o_Job);
End;"
when i call this package from php using OCI i should get the results as
below
o_EmpNo o_EName o_job
7499ALLEN   SALESMAN
7698BLAKE   MANAGER
7900JAMES   CLERK
7566JONES   MANAGER
7934MILLER  CLERK
7844TURNER  SALESMAN

but iam getting error msg as
Warning: ociexecute(): OCIStmtExecute: ORA-06550: line 1, column 7:
PLS-00306: wrong number or types of arguments in call to
'EMPLOYEESEARCH' ORA-06550: line 1, column 7: PLS-00306: wrong number
or types of arguments in call to 'EMPLOYEESEARCH' ORA-06550: line 1,
column 7: PLS-00306: wrong number or types of arguments in call to
'EMPLOYEESEARCH' ORA-06550: line 1, column 7: PL/SQL: Statement ignored
in c:\apache group\apache\htdocs\

here is the code that i executed

$sql = "declare o_EmpNo Employee_pkg.tblEmpNo;o_EName
Employee_pkg.tblEName;o_Job Employee_pkg.tblJob;"; 
$sql = "Begin
Employee_pkg.EmployeeSearch('e',:o_EmpNo,:o_EName,:o_Job);End;";

$conn   = OCILogon("scott","tiger");
$stmt   = OCIParse($conn,$sql);

   OCIBindByname($stmt,':o_Empno',$o_array1);
   OCIBindByname($stmt,':o_EName',$o_timestamp);
   OCIBindByname($stmt,':o_Job',$o_array2);
   OCIExecute($stmt);
  
   OCILogoff($conn);



[2004-01-12 19:27:36] [EMAIL PROTECTED]

Can you tell us what error exactly do you get?
Are there any error messages? Currently I can't understand what are you
talking about, sorry.



[2004-01-04 23:21:17] mbaranidharan at yahoo dot com

Iam trying to call a pac

#26892 [Opn->Asn]: ocinewcollection fails with Oracle 9.2

2004-01-15 Thread tony2001
 ID:   26892
 Updated by:   [EMAIL PROTECTED]
 Reported By:  tomy at envox dot hr
-Status:   Open
+Status:   Assigned
 Bug Type: OCI8 related
 Operating System: Suse 8.2
 PHP Version:  4CVS-2004-01-13 (stable)
-Assigned To:  
+Assigned To:  tony2001
 New Comment:

I'm currently working on it.


Previous Comments:


[2004-01-15 06:00:55] tomy at envox dot hr

The *COLLECTIONS* defines have been fixed now.

Unfortunately the original bug submitted still exists!

Output from reproducable script follows (ocinewcollection fails and
returns false with a warning):
"
OCIDebug: _oci_open_server new conn=0
dname=(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=192.168.3.41)(PORT=1521)))(CONNECT_DATA=(SID=pirana)(SERVER=DEDICATED)))
OCIDebug: _oci_open_session new sess=3 user=system
OCIDebug: oci_do_connect: id=4

Warning: ocinewcollection() [function.ocinewcollection]: OCITypeByName:
ORA-21301: not initialized in object mode in
/srv/www/htdocs/envox/info2.php on line 14
Collection failed
OCIDebug: START php_rshutdown_oci
OCIDebug: END php_rshutdown_oci
OCIDebug: START _oci_coll_list_dtor: 5
OCIDebug: END _oci_coll_list_dtor: 5
OCIDebug: START _oci_conn_list_dtor: id=4
OCIDebug: nothing to do..
OCIDebug: START _oci_close_session: logging-off sess=3
OCIDebug: END _oci_conn_list_dtor: id=4
"



[2004-01-15 05:27:01] [EMAIL PROTECTED]

The snapshot is too old. (the 'typo' is fixed in CVS, snapshot just
doesn't have the changes in it yet)
Get the latest snapshot now.




[2004-01-15 03:47:52] tomy at envox dot hr

The *COLLECTIONS* defines have NOT been fixed!!!
At least not in php5-200401150630 found in 
http://snaps.php.net/php5-latest.tar.gz.

You still define HAVE_OCI8_COLLECTIONS in configure and use
PHP_OCI8_HAVE_COLLECTIONS in ext/oci8/oci8.c. Also have
HAVE_OCI8_COLLECTIONS in all other files and once in ext/oci8/oci8.c.
The one use of HAVE_OCI8_COLLECTIONS is conviniently placed in
PHP_MINFO_FUNCTION so phpinfo() says that collection support is
enabled. However all collection methods are wrapped inside
PHP_OCI8_HAVE_COLLECTIONS so they are actually not present.

Simple recursive search yields:

Find 'PHP_OCI8_HAVE_COLLECTIONS' in 'ext/oci8/oci8.c' :
ext/oci8/oci8.c/84: #ifdef PHP_OCI8_HAVE_COLLECTIONS 
ext/oci8/oci8.c/90: #ifdef PHP_OCI8_HAVE_COLLECTIONS
ext/oci8/oci8.c/193: #ifdef PHP_OCI8_HAVE_COLLECTIONS
ext/oci8/oci8.c/208: #ifdef PHP_OCI8_HAVE_COLLECTIONS
ext/oci8/oci8.c/262: #ifdef PHP_OCI8_HAVE_COLLECTIONS
ext/oci8/oci8.c/351: #ifdef PHP_OCI8_HAVE_COLLECTIONS
ext/oci8/oci8.c/434: #ifdef PHP_OCI8_HAVE_COLLECTIONS
ext/oci8/oci8.c/484: #ifdef PHP_OCI8_HAVE_COLLECTIONS
ext/oci8/oci8.c/523: #ifdef PHP_OCI8_HAVE_COLLECTIONS
ext/oci8/oci8.c/602: #ifdef PHP_OCI8_HAVE_COLLECTIONS
ext/oci8/oci8.c/608: #ifdef PHP_OCI8_HAVE_COLLECTIONS
ext/oci8/oci8.c/616: #ifdef PHP_OCI8_HAVE_COLLECTIONS
ext/oci8/oci8.c/648: #ifdef PHP_OCI8_HAVE_COLLECTIONS
ext/oci8/oci8.c/655: #ifdef PHP_OCI8_HAVE_COLLECTIONS
ext/oci8/oci8.c/660: #ifdef PHP_OCI8_HAVE_COLLECTIONS
ext/oci8/oci8.c/685: #ifdef PHP_OCI8_HAVE_COLLECTIONS
ext/oci8/oci8.c/1051: #ifdef PHP_OCI8_HAVE_COLLECTIONS
ext/oci8/oci8.c/1412: #ifdef PHP_OCI8_HAVE_COLLECTIONS
ext/oci8/oci8.c/3604: #ifdef PHP_OCI8_HAVE_COLLECTIONS
ext/oci8/oci8.c/3633: #ifdef PHP_OCI8_HAVE_COLLECTIONS
ext/oci8/oci8.c/3751: #ifdef PHP_OCI8_HAVE_COLLECTIONS
ext/oci8/oci8.c/6221: #ifdef PHP_OCI8_HAVE_COLLECTIONS

Find 'HAVE_OCI8_COLLECTIONS' in 'configure' :
configure/57304: #define HAVE_OCI8_COLLECTIONS 1
ext/oci8/config.m4/146: AC_DEFINE(HAVE_OCI8_COLLECTIONS,1,[ ])
ext/oci8/oci8.c/806: #ifdef HAVE_OCI8_COLLECTIONS
main/php_config.h.in/1826: #undef HAVE_OCI8_COLLECTIONS

Also after having fixed defines by replacing all
PHP_OCI8_HAVE_COLLECTIONS with HAVE_OCI8_COLLECTIONS the original bug
remains



[2004-01-15 01:26:41] [EMAIL PROTECTED]

Please try using this CVS snapshot:

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

The *COLLECTIONS* defines have been fixed.




[2004-01-13 13:44:58] [EMAIL PROTECTED]

Please, try PHP5 latest snapshots and check if it works with them.



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

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


#26892 [Asn->Csd]: ocinewcollection fails with Oracle 9.2

2004-01-15 Thread tony2001
 ID:   26892
 Updated by:   [EMAIL PROTECTED]
 Reported By:  tomy at envox dot hr
-Status:   Assigned
+Status:   Closed
 Bug Type: OCI8 related
 Operating System: Suse 8.2
 PHP Version:  4CVS-2004-01-13 (stable)
 Assigned To:  tony2001
 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.

Thanks for reporting.


Previous Comments:


[2004-01-15 09:34:56] [EMAIL PROTECTED]

I'm currently working on it.



[2004-01-15 06:00:55] tomy at envox dot hr

The *COLLECTIONS* defines have been fixed now.

Unfortunately the original bug submitted still exists!

Output from reproducable script follows (ocinewcollection fails and
returns false with a warning):
"
OCIDebug: _oci_open_server new conn=0
dname=(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=192.168.3.41)(PORT=1521)))(CONNECT_DATA=(SID=pirana)(SERVER=DEDICATED)))
OCIDebug: _oci_open_session new sess=3 user=system
OCIDebug: oci_do_connect: id=4

Warning: ocinewcollection() [function.ocinewcollection]: OCITypeByName:
ORA-21301: not initialized in object mode in
/srv/www/htdocs/envox/info2.php on line 14
Collection failed
OCIDebug: START php_rshutdown_oci
OCIDebug: END php_rshutdown_oci
OCIDebug: START _oci_coll_list_dtor: 5
OCIDebug: END _oci_coll_list_dtor: 5
OCIDebug: START _oci_conn_list_dtor: id=4
OCIDebug: nothing to do..
OCIDebug: START _oci_close_session: logging-off sess=3
OCIDebug: END _oci_conn_list_dtor: id=4
"



[2004-01-15 05:27:01] [EMAIL PROTECTED]

The snapshot is too old. (the 'typo' is fixed in CVS, snapshot just
doesn't have the changes in it yet)
Get the latest snapshot now.




[2004-01-15 03:47:52] tomy at envox dot hr

The *COLLECTIONS* defines have NOT been fixed!!!
At least not in php5-200401150630 found in 
http://snaps.php.net/php5-latest.tar.gz.

You still define HAVE_OCI8_COLLECTIONS in configure and use
PHP_OCI8_HAVE_COLLECTIONS in ext/oci8/oci8.c. Also have
HAVE_OCI8_COLLECTIONS in all other files and once in ext/oci8/oci8.c.
The one use of HAVE_OCI8_COLLECTIONS is conviniently placed in
PHP_MINFO_FUNCTION so phpinfo() says that collection support is
enabled. However all collection methods are wrapped inside
PHP_OCI8_HAVE_COLLECTIONS so they are actually not present.

Simple recursive search yields:

Find 'PHP_OCI8_HAVE_COLLECTIONS' in 'ext/oci8/oci8.c' :
ext/oci8/oci8.c/84: #ifdef PHP_OCI8_HAVE_COLLECTIONS 
ext/oci8/oci8.c/90: #ifdef PHP_OCI8_HAVE_COLLECTIONS
ext/oci8/oci8.c/193: #ifdef PHP_OCI8_HAVE_COLLECTIONS
ext/oci8/oci8.c/208: #ifdef PHP_OCI8_HAVE_COLLECTIONS
ext/oci8/oci8.c/262: #ifdef PHP_OCI8_HAVE_COLLECTIONS
ext/oci8/oci8.c/351: #ifdef PHP_OCI8_HAVE_COLLECTIONS
ext/oci8/oci8.c/434: #ifdef PHP_OCI8_HAVE_COLLECTIONS
ext/oci8/oci8.c/484: #ifdef PHP_OCI8_HAVE_COLLECTIONS
ext/oci8/oci8.c/523: #ifdef PHP_OCI8_HAVE_COLLECTIONS
ext/oci8/oci8.c/602: #ifdef PHP_OCI8_HAVE_COLLECTIONS
ext/oci8/oci8.c/608: #ifdef PHP_OCI8_HAVE_COLLECTIONS
ext/oci8/oci8.c/616: #ifdef PHP_OCI8_HAVE_COLLECTIONS
ext/oci8/oci8.c/648: #ifdef PHP_OCI8_HAVE_COLLECTIONS
ext/oci8/oci8.c/655: #ifdef PHP_OCI8_HAVE_COLLECTIONS
ext/oci8/oci8.c/660: #ifdef PHP_OCI8_HAVE_COLLECTIONS
ext/oci8/oci8.c/685: #ifdef PHP_OCI8_HAVE_COLLECTIONS
ext/oci8/oci8.c/1051: #ifdef PHP_OCI8_HAVE_COLLECTIONS
ext/oci8/oci8.c/1412: #ifdef PHP_OCI8_HAVE_COLLECTIONS
ext/oci8/oci8.c/3604: #ifdef PHP_OCI8_HAVE_COLLECTIONS
ext/oci8/oci8.c/3633: #ifdef PHP_OCI8_HAVE_COLLECTIONS
ext/oci8/oci8.c/3751: #ifdef PHP_OCI8_HAVE_COLLECTIONS
ext/oci8/oci8.c/6221: #ifdef PHP_OCI8_HAVE_COLLECTIONS

Find 'HAVE_OCI8_COLLECTIONS' in 'configure' :
configure/57304: #define HAVE_OCI8_COLLECTIONS 1
ext/oci8/config.m4/146: AC_DEFINE(HAVE_OCI8_COLLECTIONS,1,[ ])
ext/oci8/oci8.c/806: #ifdef HAVE_OCI8_COLLECTIONS
main/php_config.h.in/1826: #undef HAVE_OCI8_COLLECTIONS

Also after having fixed defines by replacing all
PHP_OCI8_HAVE_COLLECTIONS with HAVE_OCI8_COLLECTIONS the original bug
remains



[2004-01-15 01:26:41] [EMAIL PROTECTED]

Please try using this CVS snapshot:

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

The *COLLECTIONS* defines have been fixed.




The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug re

#25123 [Opn->Fbk]: ocierror() returns always ORA-24315 illegal attribute type

2004-01-15 Thread tony2001
 ID:   25123
 Updated by:   [EMAIL PROTECTED]
 Reported By:  karel dot miarka at issa dot cz
-Status:   Open
+Status:   Feedback
 Bug Type: OCI8 related
 Operating System: Windows 2000
 PHP Version:  4CVS-2003-12-15
 New Comment:

It seems, that this is not PHP bug,
http://users.pandora.be/jbosman/jbsql/ - this page says, that "If you
get "ORA-24315: illegal attribute type" every time you get another
Oracle error, then  you don't have the Oracle 8i home as your primary
Oracle home. Use the Oracle Home Selector to change it".
I'm not able to check if this is true, 'cause there is no such old
Oracle around. Check it, plz.


Previous Comments:


[2004-01-13 03:44:38] karel dot miarka at issa dot cz

Still invalid. There's maybe problem between the Oracle 8.1 Windows
client and the Oracle 8.0 Linux server, because it works fine on
Linux.

4.3.5RC2-dev
PHP ocierror() bug
OCIDebug: _oci_open_server new conn=0 dname=xxx
OCIDebug: _oci_open_session new sess=3 user=yyy
OCIDebug: oci_do_connect: id=4
OCIDebug: oci_parse "SELECT xyz12345 FROM no_table123" id=5 conn=4

Warning: ociexecute(): OCIStmtExecute: ORA-00942: tabulka nebo pohled
neexistuje in c:\www\tests\ocierror.php on line 12
ocierror($stmt): Array ( [code] => 24315 [message] => ORA-24315:
neplatný typ atributu [offset] => 21 [sqltext] => ) 1
OCIDebug: START _oci_stmt_list_dtor: id=5 last_query="SELECT xyz12345
FROM no_table123"
OCIDebug: END _oci_stmt_list_dtor: id=5
OCIDebug: START php_rshutdown_oci
OCIDebug: END php_rshutdown_oci
OCIDebug: START _oci_conn_list_dtor: id=4
OCIDebug: nothing to do..
OCIDebug: END _oci_conn_list_dtor: id=4
OCIDebug: START _oci_close_session: logging-off sess=3
OCIDebug: START _oci_close_server: detaching conn=2 dbname=xxx



[2004-01-12 07:07:25] [EMAIL PROTECTED]

Please try using this CVS snapshot:

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





[2003-12-16 09:00:35] karel dot miarka at issa dot cz

Output of the "reproduce code" (see below) when ociinternaldebug(1)
called first:

OCIDebug: _oci_open_server new conn=0 dname=xyz
OCIDebug: _oci_open_session new sess=3 user=xyz123
OCIDebug: oci_do_connect: id=4
OCIDebug: oci_parse "SELECT xyz12345 FROM no_table123" id=5 conn=4

Warning: ociexecute(): OCIStmtExecute: ORA-00942: table or view doesn't
exist in c:\www\tests\ocierror.php on line 10
ocierror($stmt): Array ( [code] => 24315 [message] => ORA-24315:
illegal attribute type [offset] => 21 [sqltext] => ) 1
OCIDebug: START _oci_stmt_list_dtor: id=5 last_query="SELECT xyz12345
FROM no_table123"
OCIDebug: END _oci_stmt_list_dtor: id=5
OCIDebug: START php_rshutdown_oci
OCIDebug: END php_rshutdown_oci
OCIDebug: START _oci_conn_list_dtor: id=4
OCIDebug: nothing to do..
OCIDebug: END _oci_conn_list_dtor: id=4
OCIDebug: START _oci_close_session: logging-off sess=3
OCIDebug: START _oci_close_server: detaching conn=2 dbname=xyz



[2003-12-15 16:55:12] [EMAIL PROTECTED]

Try the ociinternaldebug(1); like suggested by cjbj at hotmail dot com





[2003-12-15 09:37:14] karel dot miarka at issa dot cz

Our Oracle server version is 8.0.5.0.0 , so maybe that's the problem,
but it was working fine with older versions of php.



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

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


#26738 [Opn->Asn]: PHP-OCI binding error

2004-01-21 Thread tony2001
 ID:   26738
 Updated by:   [EMAIL PROTECTED]
 Reported By:  mbaranidharan at yahoo dot com
-Status:   Open
+Status:   Assigned
 Bug Type: OCI8 related
 Operating System: *
 PHP Version:  4.3.4
-Assigned To:  
+Assigned To:  tony2001
 New Comment:

This can be definitely done with collections.
First, you need to create name type:
create type employee(id INTEGER, name VARCHAR2, job VARCHAR2); -- for
example
then in PL/SQL:
PROCEDURE EmployeeSearch 
   (i_EName IN VARCHAR2, 
employee_var OUT employee
) 
IS
BEGIN 
--seeking for 
--matching emplyees...
   employee_var := employee(123,"name","job");
END EmployeeSearch;

and in PHP you should do smthng like this:
getelem(0);
//etc...
?>

Currently oci_collection_element_get() doesn't support subcollections,
so I assign this bug to myself.
Will add this possibility soon.


Previous Comments:


[2004-01-19 01:12:32] mbaranidharan at yahoo dot com

but in my case iam trying to return a plsql table type from the
procedure. So i cant create a type of plsql table outside which oracle
wont allow.
So can't use ocinewcollection and ocicoll* functions.
pls try to create the packages i have send and check.
-
Thanks



[2004-01-15 08:40:39] [EMAIL PROTECTED]

Aha, I got your point at least. It seems, that you need to use
ocinewcollection() and other ocicoll*() functions to work with these
user-defined types.



[2004-01-13 23:16:56] mbaranidharan at yahoo dot com

my procedure does not return any cursor here it will return a pl/sql
table. Its using cursor to fetch data and populate into pl/sql table.
Basically the error come when i try to bind an array to variable. Look
at my procedure below
PROCEDURE EmployeeSearch 
   (i_EName IN VARCHAR2, 
o_EmpNo OUT tblEmpNo, 
o_EName OUT tblEName, 
o_Job OUT tblJob); 
END Employee_Pkg;
it takes in one parameter and returns 3 out parameters which is of
table type not cursor.



[2004-01-13 13:20:02] [EMAIL PROTECTED]

First, you need to allocate new descriptor with ocinewdescriptor().
Your stored proc will return cursor, using this descriptor. After this
your should fetch data from this cursor, as you usually do with query
results.
And second:
after these two lines your variable contains only "Begin etc.". Use
$sql .= in second line.
---
#1 sql = "declare o_EmpNo Employee_pkg.tblEmpNo;o_EName
Employee_pkg.tblEName;o_Job Employee_pkg.tblJob;"; 
#2 $sql = "Begin
Employee_pkg.EmployeeSearch('e',:o_EmpNo,:o_EName,:o_Job);End;";
---

This doesn't look like a bug, bogusifying it..



[2004-01-12 23:54:28] mbaranidharan at yahoo dot com

Below i have given the package and package body created in oracle
database.
*
CREATE PACKAGE Employee_Pkg 
AS 
TYPE tblEmpNo IS TABLE OF NUMBER(4) INDEX BY BINARY_INTEGER; 
TYPE tblEName IS TABLE OF VARCHAR2(10) INDEX BY BINARY_INTEGER; 
TYPE tblJob IS TABLE OF VARCHAR2(9) INDEX BY BINARY_INTEGER; 

PROCEDURE EmployeeSearch 
   (i_EName IN VARCHAR2, 
o_EmpNo OUT tblEmpNo, 
o_EName OUT tblEName, 
o_Job OUT tblJob); 
END Employee_Pkg;
/
CREATE PACKAGE BODY Employee_Pkg 
AS 
PROCEDURE EmployeeSearch 
   (i_EName IN VARCHAR2, 
o_EmpNo OUT tblEmpNo, 
o_EName OUT tblEName, 
o_Job OUT tblJob) 
IS
CURSOR cur_employee (curName VARCHAR2) IS 
  SELECT empno, 
 ename, 
 job 
  FROM emp 
  WHERE UPPER(ename) LIKE '%' || UPPER(curName) || '%' 
  ORDER BY ename; 
  RecordCount NUMBER DEFAULT 0;
BEGIN 
  FOR curRecEmployee IN cur_employee(i_EName) LOOP 
 RecordCount:= RecordCount + 1; 
 o_EmpNo(RecordCount):= curRecEmployee.empno; 
 o_EName(RecordCount):= curRecEmployee.ename; 
 o_Job(RecordCount):= curRecEmployee.job; 
  END LOOP; 
   END EmployeeSearch; 
END Employee_Pkg;
/
*
Below is my sql block calling the package

SQL="declare 
o_EmpNo Employee_pkg.tblEmpNo; 
o_EName Employee_pkg.tblEName; 
o_Job Employee_pkg.tblJob; 
Begin Employee_pkg.EmployeeSearch('e',:o_EmpNo,:o_EName,:o_Job);
End;"
when i call this package from php using OCI i should get the results as
below
o_EmpNo o_EName o_job
7499ALLEN   SALESMAN
7698BLAKE   MANAGER
7900JAMES   CLERK
7566JONES   MANAGER
7934MILLER  CLERK
7844TURNER  SALESMAN

but iam getting error msg as
Warning: ociexecute(): OCIStmtExecute: ORA-06550: line 1, column 7:
PLS-00306: wrong num

#27083 [Opn->Fbk]: binding blobs to procedure params corrupts them

2004-01-29 Thread tony2001
 ID:   27083
 Updated by:   [EMAIL PROTECTED]
 Reported By:  ceco at noxis dot net
-Status:   Open
+Status:   Feedback
 Bug Type: OCI8 related
 Operating System: windows 2000 server
 PHP Version:  4.3.4
 New Comment:

Don't use writeTemporary, it's not intended for writing persistent
LOB's.
You should use save() or you can upgrade to PHP5 and use $lob->write()
method.


Previous Comments:


[2004-01-29 06:29:33] ceco at noxis dot net

Description:

first of all I should say that it may be documentation problem, because
didn't find good documentation of the LOB object 

i have a oracle procedure, which accepts BLOB

(see the code below)

it inputs the data in the blob but when i extract (with the oracle
tools or with other php script) it is corrupted it is exactly 2 times
larger
when everything is changed to clob (of course the data is text not
jpg), this function work ok

also it is workig for me if I use insert into (the_blob) values
(empty_blob()) returning the_blob into :the_blob

and then bind $lob and use $lob->save

but i don't want to have this

I think $lob->WriteTemporary mangles the data somehow and corrupts it

Reproduce code:
---
include_once 'config/environment.inc.php';

$fd = fopen('Sample.jpg', 'r');
$data = fread($fd, filesize('Sample.jpg'));
fclose($fd);

$conn = ocilogon($CFG_DB['username'], $CFG_DB['password'],
$CFG_DB['db']);
$lob = OCINewDescriptor($conn, OCI_D_LOB);

$stmt = OCIParse($conn,"begin TEST_PROC(:the_blob); end;");
OCIBindByName($stmt, ':the_blob', &$lob, -1, OCI_B_BLOB);
$lob->WriteTemporary($data);
OCIExecute($stmt, OCI_DEFAULT);
$lob->close();
$lob->free();
OCICommit($conn);


create procedure TEST_PROC(the_blob blob) is
begin
insert into test_table values (the_blob);
end;

create table test_table (the_blob blob);






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


#27083 [Opn->Asn]: binding blobs to procedure params corrupts them

2004-01-29 Thread tony2001
 ID:   27083
 Updated by:   [EMAIL PROTECTED]
 Reported By:  ceco at noxis dot net
-Status:   Open
+Status:   Assigned
 Bug Type: OCI8 related
 Operating System: windows 2000 server
 PHP Version:  4.3.4
-Assigned To:  
+Assigned To:  tony2001
 New Comment:

ok, I'll take a look at it soon.


Previous Comments:


[2004-01-29 11:16:59] ceco at noxis dot net

in examle 2 on
http://www.php.net/manual/en/function.ocinewdescriptor.php

it is used exactly like that, only it is clob

I cannot use php 5, I made workaround converting blob to hex, sending
it as clob and then reconverting it to binary ;-))
a little strange and cpu intensive but works and since it is not very
often used I'll have to leave it that way



[2004-01-29 09:21:23] [EMAIL PROTECTED]

Don't use writeTemporary, it's not intended for writing persistent
LOB's.
You should use save() or you can upgrade to PHP5 and use $lob->write()
method.



[2004-01-29 06:29:33] ceco at noxis dot net

Description:

first of all I should say that it may be documentation problem, because
didn't find good documentation of the LOB object 

i have a oracle procedure, which accepts BLOB

(see the code below)

it inputs the data in the blob but when i extract (with the oracle
tools or with other php script) it is corrupted it is exactly 2 times
larger
when everything is changed to clob (of course the data is text not
jpg), this function work ok

also it is workig for me if I use insert into (the_blob) values
(empty_blob()) returning the_blob into :the_blob

and then bind $lob and use $lob->save

but i don't want to have this

I think $lob->WriteTemporary mangles the data somehow and corrupts it

Reproduce code:
---
include_once 'config/environment.inc.php';

$fd = fopen('Sample.jpg', 'r');
$data = fread($fd, filesize('Sample.jpg'));
fclose($fd);

$conn = ocilogon($CFG_DB['username'], $CFG_DB['password'],
$CFG_DB['db']);
$lob = OCINewDescriptor($conn, OCI_D_LOB);

$stmt = OCIParse($conn,"begin TEST_PROC(:the_blob); end;");
OCIBindByName($stmt, ':the_blob', &$lob, -1, OCI_B_BLOB);
$lob->WriteTemporary($data);
OCIExecute($stmt, OCI_DEFAULT);
$lob->close();
$lob->free();
OCICommit($conn);


create procedure TEST_PROC(the_blob blob) is
begin
insert into test_table values (the_blob);
end;

create table test_table (the_blob blob);






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


#27083 [Asn->Fbk]: binding blobs to procedure params corrupts them

2004-02-04 Thread tony2001
 ID:   27083
 Updated by:   [EMAIL PROTECTED]
 Reported By:  ceco at noxis dot net
-Status:   Assigned
+Status:   Feedback
 Bug Type: OCI8 related
 Operating System: windows 2000 server
 PHP Version:  4.3.4
 Assigned To:  tony2001
 New Comment:

In php 4.3.x method writeTemporary() doesn't accept second parameter,
which exists only in php5 branch.
This parameter should be used to tell method wich type of Lob you're
trying to write.
Thus, in php4.3.x writeTemporary always tries to create CLOB, and
you're using it to write BLOB.
The example in docs should be changed, I'm working on new docs atm.


Previous Comments:


[2004-01-29 11:46:35] [EMAIL PROTECTED]

ok, I'll take a look at it soon.



[2004-01-29 11:16:59] ceco at noxis dot net

in examle 2 on
http://www.php.net/manual/en/function.ocinewdescriptor.php

it is used exactly like that, only it is clob

I cannot use php 5, I made workaround converting blob to hex, sending
it as clob and then reconverting it to binary ;-))
a little strange and cpu intensive but works and since it is not very
often used I'll have to leave it that way



[2004-01-29 09:21:23] [EMAIL PROTECTED]

Don't use writeTemporary, it's not intended for writing persistent
LOB's.
You should use save() or you can upgrade to PHP5 and use $lob->write()
method.



[2004-01-29 06:29:33] ceco at noxis dot net

Description:

first of all I should say that it may be documentation problem, because
didn't find good documentation of the LOB object 

i have a oracle procedure, which accepts BLOB

(see the code below)

it inputs the data in the blob but when i extract (with the oracle
tools or with other php script) it is corrupted it is exactly 2 times
larger
when everything is changed to clob (of course the data is text not
jpg), this function work ok

also it is workig for me if I use insert into (the_blob) values
(empty_blob()) returning the_blob into :the_blob

and then bind $lob and use $lob->save

but i don't want to have this

I think $lob->WriteTemporary mangles the data somehow and corrupts it

Reproduce code:
---
include_once 'config/environment.inc.php';

$fd = fopen('Sample.jpg', 'r');
$data = fread($fd, filesize('Sample.jpg'));
fclose($fd);

$conn = ocilogon($CFG_DB['username'], $CFG_DB['password'],
$CFG_DB['db']);
$lob = OCINewDescriptor($conn, OCI_D_LOB);

$stmt = OCIParse($conn,"begin TEST_PROC(:the_blob); end;");
OCIBindByName($stmt, ':the_blob', &$lob, -1, OCI_B_BLOB);
$lob->WriteTemporary($data);
OCIExecute($stmt, OCI_DEFAULT);
$lob->close();
$lob->free();
OCICommit($conn);


create procedure TEST_PROC(the_blob blob) is
begin
insert into test_table values (the_blob);
end;

create table test_table (the_blob blob);






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


#26829 [NoF->Asn]: Killed Oracle Sessions openned with OCIPLogon()

2004-02-04 Thread tony2001
 ID:   26829
 Updated by:   [EMAIL PROTECTED]
 Reported By:  david dot gaia dot kano at dartmouth dot edu
-Status:   No Feedback
+Status:   Assigned
 Bug Type: OCI8 related
 Operating System: Compaq Unix
 PHP Version:  4.3.4
-Assigned To:  
+Assigned To:  tony2001
 New Comment:

This is known issue and should be fixed in future releases of PHP5.



Previous Comments:


[2004-01-19 14:12:22] [EMAIL PROTECTED]

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





[2004-01-07 20:14:23] [EMAIL PROTECTED]

Please try using this CVS snapshot:

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

AFAICT, the function does check if persistent connection is still alive
(using oci_ping())..but did you mean the connection is killed while the
script is being run or what?




[2004-01-07 11:36:45] david dot gaia dot kano at dartmouth dot edu

Description:

Here at Dartmouth our DBA team has a policy of killing any Oracle
session that has been connected for longer than 24 hours. Hence the
persistant connections created by the PHP OCIPLogon() call get killed
once a day. We don't really want to restart our apache server once a
day, so it would be great if OCIPLogon() would check to see that a
previously created persistant connection is still good somehow and if
not, create a new connection.

I noticed quite a few bugs along these lines, but they have all been
closed. I don't know if that is because this bug was fixed or because
the submitters have continued to restart their servers after every
database restart or killed connection.

If this is not going to be fixed, I guess we would have to write our
own application level code to check the connections from ociplogon()
and if it is bad, use OCILogon() instead for that request and issue a
apache_child_terminate() call so that eventually all the children with
bad oracle sessions would be restarted...

Reproduce code:
---
$con = OCIPLogon("user", "password", "tns_db_name");
// at this point all looks good still... $con != false
// but if this session was killed then any use of $con 
// results in one error or another.






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


#27149 [Asn->Csd]: Saving of CLOBS does not work in RC2 but works fine in RC1

2004-02-05 Thread tony2001
 ID:   27149
 Updated by:   [EMAIL PROTECTED]
 Reported By:  webmaster at f1-timer dot de
-Status:   Assigned
+Status:   Closed
 Bug Type: OCI8 related
 Operating System: Suse Linux 8.1
 PHP Version:  4.3.5RC2
 Assigned To:  tony2001
 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.


It was my fault =(
Already fixed in CVS, thanks for reporting.



Previous Comments:


[2004-02-04 19:11:49] [EMAIL PROTECTED]

Antony, please check this out..some MFH broke this or what?




[2004-02-04 13:19:29] webmaster at f1-timer dot de

Description:

I have many pages here that uses CLOB columns for storing large amount
of text. In 4.3.5RC1 everything works fine, clobs are correctly saved.
However I have today updated to 4.3.5RC2 and now the same code does not
work anymore, Oracle complains about ORA-24801:

  ebola:/usr/src/php-4.3.5RC2 # oerr ORA 24801
24801, 0, "illegal parameter value in OCI lob function"
// *Cause:  One of the parameter values in the OCI lob function is
illegal.
// *Action: Check every parameter in the OCI Lob function call to make
sure
//  they are correct.  Offsets should be greater than or equal
to one.


Here is my configure line:
/configure' '--with-apxs2=/opt/apache2/bin/apxs' '--enable-bcmath'
'--with-openssl=/opt/openssl' '--enable-sigchild'
'--with-pear=/html/PEAR' '--enable-libgcc'
'--with-config-file-path=/opt/apache2/conf' '--with-pdflib=/usr/local'
'--with-oci8' '--with-gd' '--with-ttf=/usr' '--with-freetype-dir=/usr'
'--enable-gd-imgstrttf' '--enable-gd-native-ttf' '--with-jpeg-dir=/usr'
'--with-png-dir=/usr' '--with-xpm-dir=/usr' '--with-t1lib=/usr'
'--enable-sysvsem' '--enable-sysvshm' '--enable-sysvmsg'
'--disable-debug' '--disable-ctype' '--with-mysql=/opt/mysql4'
'--with-zlib=/usr' '--enable-track-vars' '--enable-calendar'
'--enable-ftp' '--enable-sockets' '--with-gmp' '--disable-trans-sid'
'--enable-shmop' '--without-msql' '--with-mcal=/usr' '--with-gettext'
'--with-bz2=/usr' '--without-dom' '--enable-exif' '--with-mm=/usr'
'--enable-mbstring' '--enable-mbregex' '--enable-mime-magic'
'--enable-dbx' '--enable-dio' '--with-mcrypt=/usr/local'
'--with-tsrm-pthreads' '--with-readline' '--with-ncurses'
'--enable-dba' '--with-mhash=/usr' '--with-gdbm=/usr' '--with-dbm=/usr'
'--with-db4=/usr' '--with-libxml-dir=/opt/libxml2'

The Database is Oracle 9.2.0.4 EE 



Reproduce code:
---
The code to reproduce is actually 76 Lines long, so here is the URL to
it:

http://www.in-ovation.de/clobtest.txt


Expected result:

printing out "done."

Actual result:
--
Warning: save(): OCILobWrite: ORA-24801: Unzulässiger Parameterwert in
OCI-LOB-Funktion
 in /html/private/clobtest.php on line 62
Unable to add CLOB text to database!
done.






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


#27194 [Opn->Fbk]: select doesn't work with where clause

2004-02-09 Thread tony2001
 ID:   27194
 Updated by:   [EMAIL PROTECTED]
 Reported By:  alexandre dot fontes at uol dot com dot br
-Status:   Open
+Status:   Feedback
 Bug Type: OCI8 related
 Operating System: Red Hat 9.0
 PHP Version:  4.3.4
 New Comment:

Please, provide more info.
I need at least error message.
And it would very good, if you turn on ociinternaldebug() and
copy/paste here the output of this function.


Previous Comments:


[2004-02-09 12:46:54] alexandre dot fontes at uol dot com dot br

The NON-working version of the script:

Oracle PHP Test";
echo "Oracle PHP Test";
echo "\n\\n";
echo "Name\nSalary\n\n";

for ($i = 0; $i < $nrows; $i++ )
{
echo "\n";
echo "" . $results["NAME"][$i] . "";
echo "\n";
}

echo " Number of Rows: $nrows";
echo "If you see data, then it
works!\n";

?>



[2004-02-09 12:15:47] [EMAIL PROTECTED]

Please provide the NON-working version of the script..




[2004-02-09 12:14:00] alexandre dot fontes at uol dot com dot br

Description:

The following program runs perfectly.
But if we put an WHERE clause on SELECT command, the program fails
(Server not found).
The same SELECT command, with the same WHERE clause runs ok on
SQL*Plus.


Reproduce code:
---
Oracle PHP Test";
echo "Oracle PHP Test";
echo "\n\\n";
echo "Name\nSalary\n\n";

for ($i = 0; $i < $nrows; $i++ )
{
echo "\n";
echo "" . $results["NAME"][$i] . "";
echo "\n";
}

echo " Number of Rows: $nrows";
echo "If you see data, then it
works!\n";

?>







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


#27194 [Opn->Bgs]: select doesn't work with where clause

2004-02-09 Thread tony2001
 ID:   27194
 Updated by:   [EMAIL PROTECTED]
 Reported By:  alexandre dot fontes at uol dot com dot br
-Status:   Open
+Status:   Bogus
 Bug Type: OCI8 related
 Operating System: Red Hat 9.0
 PHP Version:  4.3.4
 New Comment:

you don't need both oracle & oci8 modules.
it's recommended to use oci8, 'cause ora_* extension is obsolete.


Previous Comments:


[2004-02-09 14:09:13] alexandre dot fontes at uol dot com dot br

PROBLEM SOLVED!!!

Originally, the PHP was compiled with the following command:

./configure \
--prefix=/usr/local/dados/php \
--exec-prefix=/usr/local/dados/php \
--with-apxs2=/usr/local/dados/apache/bin/apxs \
--enable-debug

What's wrong? The --with-oci8 and --with-oracle directives are missing,
so with:

./configure \
--prefix=/usr/local/dados/php \
--exec-prefix=/usr/local/dados/php \
--with-apxs2=/usr/local/dados/apache/bin/apxs \
--enable-debug \
--with-oracle=/oracle/ora8i \
--with-oci8=/oracle/ora8i \
--enable-sigchild

It worked!!!



[2004-02-09 13:39:21] [EMAIL PROTECTED]

Please, provide more info.
I need at least error message.
And it would very good, if you turn on ociinternaldebug() and
copy/paste here the output of this function.



[2004-02-09 12:46:54] alexandre dot fontes at uol dot com dot br

The NON-working version of the script:

Oracle PHP Test";
echo "Oracle PHP Test";
echo "\n\\n";
echo "Name\nSalary\n\n";

for ($i = 0; $i < $nrows; $i++ )
{
echo "\n";
echo "" . $results["NAME"][$i] . "";
echo "\n";
}

echo " Number of Rows: $nrows";
echo "If you see data, then it
works!\n";

?>



[2004-02-09 12:15:47] [EMAIL PROTECTED]

Please provide the NON-working version of the script..




[2004-02-09 12:14:00] alexandre dot fontes at uol dot com dot br

Description:

The following program runs perfectly.
But if we put an WHERE clause on SELECT command, the program fails
(Server not found).
The same SELECT command, with the same WHERE clause runs ok on
SQL*Plus.


Reproduce code:
---
Oracle PHP Test";
echo "Oracle PHP Test";
echo "\n\\n";
echo "Name\nSalary\n\n";

for ($i = 0; $i < $nrows; $i++ )
{
echo "\n";
echo "" . $results["NAME"][$i] . "";
echo "\n";
}

echo " Number of Rows: $nrows";
echo "If you see data, then it
works!\n";

?>







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


#26829 [Asn->Sus]: Killed Oracle Sessions openned with OCIPLogon()

2004-02-09 Thread tony2001
 ID:   26829
 Updated by:   [EMAIL PROTECTED]
 Reported By:  david dot gaia dot kano at dartmouth dot edu
-Status:   Assigned
+Status:   Suspended
 Bug Type: OCI8 related
 Operating System: Compaq Unix
 PHP Version:  4.3.4
 Assigned To:  tony2001


Previous Comments:


[2004-02-04 04:01:25] [EMAIL PROTECTED]

This is known issue and should be fixed in future releases of PHP5.




[2004-01-19 14:12:22] [EMAIL PROTECTED]

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





[2004-01-07 20:14:23] [EMAIL PROTECTED]

Please try using this CVS snapshot:

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

AFAICT, the function does check if persistent connection is still alive
(using oci_ping())..but did you mean the connection is killed while the
script is being run or what?




[2004-01-07 11:36:45] david dot gaia dot kano at dartmouth dot edu

Description:

Here at Dartmouth our DBA team has a policy of killing any Oracle
session that has been connected for longer than 24 hours. Hence the
persistant connections created by the PHP OCIPLogon() call get killed
once a day. We don't really want to restart our apache server once a
day, so it would be great if OCIPLogon() would check to see that a
previously created persistant connection is still good somehow and if
not, create a new connection.

I noticed quite a few bugs along these lines, but they have all been
closed. I don't know if that is because this bug was fixed or because
the submitters have continued to restart their servers after every
database restart or killed connection.

If this is not going to be fixed, I guess we would have to write our
own application level code to check the connections from ociplogon()
and if it is bad, use OCILogon() instead for that request and issue a
apache_child_terminate() call so that eventually all the children with
bad oracle sessions would be restarted...

Reproduce code:
---
$con = OCIPLogon("user", "password", "tns_db_name");
// at this point all looks good still... $con != false
// but if this session was killed then any use of $con 
// results in one error or another.






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


#27303 [Opn]: OCIBindByName binds numeric PHP values as characters

2004-02-19 Thread tony2001
 ID:   27303
 Updated by:   [EMAIL PROTECTED]
 Reported By:  cjbj at hotmail dot com
 Status:   Open
 Bug Type: OCI8 related
 Operating System: *
 PHP Version:  4CVS-2004-02-18 (stable)
 New Comment:

Yep, currently oci_bind_by_name uses SQLT_CHR for all types, except
LOBs, FILEs & ROWIDs.

You propose to add new constant - OCI_B_INT (SQLT_INT) to use it with
numeric values? Am I right?




Previous Comments:


[2004-02-18 02:14:18] cjbj at hotmail dot com

Description:

Numeric PHP variables seem to be treated as strings when bound with

OCIBindByName.  The means the desired number of significant digits

needs to be specified in the OCIBindByName call.  Othewise only the

most significant digit is returned.



PHP scripts could be simpler and safer to write if:



(i) a pre-existing numeric PHP variable automatically caused a

SQLT_INT bind



(ii) OCI's SQLT_INT type could be specified in the OCIBindByName

 call, with a new OCI_B_xxx define



For example, try a RETURNING INTO clause with a sequence value:



\n";

}



OCICommit($conn);



?>



The output is:



Bind variable is 1

Bind variable is 2

Bind variable is 3

Bind variable is 4

Bind variable is 5

Bind variable is 6

Bind variable is 7

Bind variable is 8

Bind variable is 9

Bind variable is 1

...



[This continues with 10 rows of 1's, then 10 rows of 2's etc. as

 if the least significant digit(s) are being stripped.]



Querying the table in a SQL*Plus sessions shows the inserts are

occuring correctly and the sequence number is increasing past nine:



MYDATA   SEQCOL

 --

Some data 1

Some data 2

Some data 3

Some data 4

Some data 5

Some data 6

Some data 7

Some data 8

Some data 9

Some data10

...

Some data   199



Expected result



Bind variable is 1

Bind variable is 2

Bind variable is 3

Bind variable is 4

Bind variable is 5

Bind variable is 6

Bind variable is 7

Bind variable is 8

Bind variable is 9

Bind variable is 10

...

Bind variable is 199



Testcase 2 is to set $mybv to a value before the OCIBindByName by

uncommenting the line marked 2nd test.  The value set is bound as a

string.  The number of digits in it will determine the maximum width

of the returned bind result.  For example if $mybv is set to 11, then

all two-digit values are displayed correctly.



Testcase 3 is to pass a width to OCIBindByName.  Uncomment the text

marked 3rd test.  This works until the number of digits in the

sequence number is greater than the passed width.



Another different testcase might be calling a PL/SQL procedure with a

IN/OUT parameter.  Although the passed value is correct, the out value

may not be.



If the current behavior is deemed desired, can this bug be made a

documentation bug?  Users may be easily tricked because there is no

mention of the default bind type being character, and the

OCIBindByName documentation "and the necessary storage space will be

allocated" could be thought to apply to PHP numeric variables.








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


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

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

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


Previous Comments:


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

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



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

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

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

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

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

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



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

Description:

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

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

In FreeBSD 5.3 there is no problem executing the script.

Reproduce code:
---
 

Expected result:

time with microseconds

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





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


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

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

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


Previous Comments:


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

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

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

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

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

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



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

Description:

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

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

In FreeBSD 5.3 there is no problem executing the script.

Reproduce code:
---
 

Expected result:

time with microseconds

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





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


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

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

What does it mean "no result"? Segfault? FALSE? Empty string? Zero?
There is _always_ a result, whatever you do.


Previous Comments:


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

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



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

Please try using this CVS snapshot:

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





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

Reproduce Code is :

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


It was cut at first post...



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

Description:

PHP Version 4.3.11

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

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

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

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

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

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

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

Expected result:

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

Actual result:
--
no result !





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


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

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

Could you please prepare a short reproduce script, which I can
copy&paste to reproduce the problem? Those parts of your code with
'xxx' and undeclared variables do not help much. Thanks. 


Previous Comments:


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

Sorry, I can't use PHP5.



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

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


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

It was cut at first post...



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

Please try using this CVS snapshot:

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

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




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

Description:

Using OCI persistant connections, I found the folowing bug :

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

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

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

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

Steps to reproduce the bug :

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

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

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

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

Regards,
F.SURLEAU


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

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


Expected result:

ORA-01756: quoted string not properly terminated

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





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


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

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

Are there any entries in the error_log ?
If so, use gdb to generate a backtrace.


Previous Comments:


[2005-04-19 14:29:42] fsurleau at skyservices dot net

No result means I have nothing because as I explained, the httpd
process hang (stop).



[2005-04-19 14:25:08] [EMAIL PROTECTED]

What does it mean "no result"? Segfault? FALSE? Empty string? Zero?
There is _always_ a result, whatever you do.



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

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



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

Please try using this CVS snapshot:

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





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

Reproduce Code is :

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


It was cut at first post...



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

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


#32771 [Opn->Asn]: is_dir() returns false for absolute path. Even if it is a folder

2005-04-19 Thread tony2001
 ID:   32771
 Updated by:   [EMAIL PROTECTED]
 Reported By:  silkensedai at online dot fr
-Status:   Open
+Status:   Assigned
 Bug Type: *Directory/Filesystem functions
 Operating System: GNU/Linux Ubuntu 5.4
 PHP Version:  5.0.4
-Assigned To:  
+Assigned To:  wez
 New Comment:

is_file() does the same thing when the owner of the file is not the
owner of the script.
IMO that's how safe_mode works. 
Wez, is this the expected behaviour or am I wrong?


Previous Comments:


[2005-04-19 17:56:46] silkensedai at online dot fr

Also: safe mode is enabled



[2005-04-19 17:31:26] silkensedai at online dot fr

Description:

is_dir() does not work when the folder is an absolute path.

For example is_dir('/mnt') won't work (return false).
But it works for relative path.

Example:

$ php -r 'clearstatcache();var_dump(is_dir("/mnt/"));' bool(false)
$ php -r 'clearstatcache();var_dump(is_dir("./Templates"));'
bool(true)
$ test -d "/mnt/" && echo dir || echo not_dir
dir
$ test -d "./Templates" && echo dir || echo not_dir
dir


>From phpinfo(): PHP Version 5.0.4
System: Linux louve 2.6.10-5-386 #1 Tue Apr 5 12:12:40 UTC 2005 i686
Configure Command:  './configure' '--quiet' '--enable-cli'
'--enable-cgi' '--disable-all' '--disable-rpath' '--disable-debug'
'--disable-path-info-check' '--disable-magic-quotes' '--disable-posix'
'--disable-short-tags' '--enable-ipv6' '--disable-static'
'--disable-pcntl' '--without-pear' '--with-apxs2=/usr/bin/apxs2'
'--with-mysql=/usr' '--with-mysqli=/usr/bin/mysql_config' '--with-zlib'
'--with-bz2' '--with-dbx' '--with-ctype' '--with-openssl'
'--with-pcre-regex' '--with-gettext' '--with-mcrypt' '--with-mhash'
'--with-iconv' '--with-sqlite' '--with-sqlite-utf8' '--with-gd'
'--with-jpeg-dir' '--with-png-dir' '--with-zlib-dir' '--with-xpm-dir'
'--with-ttf' '--with-xsl' '--with-tsrm-pthreads' '--with-tidy'
'--with-freetype-dir' '--enable-gd-native-ttf' '--enable-safe-mode'
'--enable-calendar' '--enable-mbstring' '--enable-spl' '--enable-ftp'
'--enable-bcmath' '--enable-sockets' '--enable-dom' '--enable-xml'
'--enable-soap' '--enable-libxml' '--enable-session'
'--enable-simplexml' '--enable-memory-limit'
Server API  Apache 2.0 Handler
PHP API 20031224
PHP Extension   20041030
Zend Extension  220040412 

Reproduce code:
---
print is_dir('/')?"dir: /":"not_dir: /";

Expected result:

dir: /

Actual result:
--
not_dir: /





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


#32770 [Opn->Fbk]: Unable to open base address file in Unknown on line 0

2005-04-19 Thread tony2001
 ID:   32770
 Updated by:   [EMAIL PROTECTED]
 Reported By:  renich at woralelandia dot com
-Status:   Open
+Status:   Feedback
 Bug Type: *General Issues
 Operating System: Windows XP
 PHP Version:  5.0.4
 New Comment:

Does this error message appear only when Zend Optimizer is enabled?


Previous Comments:


[2005-04-19 16:44:26] renich at woralelandia dot com

Description:

Ok, I don't really know what this error means, but I have been looking
in the net for quite a while and found only one thread related to
this... and the solution did not work.

The thread says its Zend Optimizer related.

I'll tell you what I did.

First checked it was a php error by disabling php in apache. Its output
was none.

I enabled php and disabled all the extensions in the php.ini file.
[19-Apr-2005 09:31:22] PHP Fatal error:  Unable to open base address
file in Unknown on line 0

I re-enabled the extensions and same output ([19-Apr-2005 09:31:22] PHP
Fatal error:  Unable to open base address file in Unknown on line 0).

I want to know whats up with this error. Is it a security issue? Is it
an optimizer issue? Why doesn't zend have anything about it? Maybe I'm
just a bad Web Investigator...

Im running php 5.0.4 on apache 2.0.53 in module mode.

Expected result:

No errors on PHP startup

Actual result:
--
[19-Apr-2005 09:31:22] PHP Fatal error:  Unable to open base address
file in Unknown on line 0





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


#32751 [Opn->Fbk]: Segfault after code execution (destructor calls)

2005-04-19 Thread tony2001
 ID:   32751
 Updated by:   [EMAIL PROTECTED]
 Reported By:  prism at pld-linux dot org
-Status:   Open
+Status:   Feedback
 Bug Type: Zend Engine 2 problem
 Operating System: PLD Linux Distribution
 PHP Version:  5.0.4
 New Comment:

Are you able to reproduce it under a different OS?
Or at least with different glibc?
Is it reproducible only with Apache2 or with CLI too?
As far as I can see, mysql is built as shared module or am I wrong?


Previous Comments:


[2005-04-19 21:20:11] prism at pld-linux dot org

What else do you need? You have been given exact cause and 
explanation what to fix. Let me know if we can still give 
you some more information.



[2005-04-19 08:51:00] [EMAIL PROTECTED]

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

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

Thank you for your interest in PHP.






[2005-04-18 21:49:05] prism at pld-linux dot org

Description:

Zend engine or all modules which use persistent_list. 
persistent_list is destroyed after modules are unloaded. 
But some modules register own destructors for elements put 
on 
persistent_list. When Zend destroys such entry from 
persistent_list, 
it tries to call destructor from unloaded module and 
segfaults. 

Reproduce code:
---
Look here: http://comments.gmane.org/gmane.linux.pld.devel.english/785
and start reading from post written at 16 Apr 17:33 by Michal Lukaszek,
and below from that.

Expected result:

No segfault. 

Actual result:
--
> (gdb) bt 
> #0  0xb78a6978 in ?? () 
> #1  0xb7f557da in plist_entry_destructor (ptr=0x81e11b8) 
> 
at /home/comp/rpm/BUILD/php-5.0.4/Zend/zend_list.c:204 
> #2  0xb7f5385f in zend_hash_apply_deleter (ht=0x8052c50, 
p=0x81ec1a0) 
> 
at /home/comp/rpm/BUILD/php-5.0.4/Zend/zend_hash.c:574 
> #3  0xb7f53ab0 in zend_hash_graceful_reverse_destroy 
(ht=0x8052c50) 
> 
at /home/comp/rpm/BUILD/php-5.0.4/Zend/zend_hash.c:640 
> #4  0xb7f558f6 in zend_destroy_rsrc_list (ht=0x8052c50, 
tsrm_ls=0x804f0a0) 
> 
at /home/comp/rpm/BUILD/php-5.0.4/Zend/zend_list.c:234 
> #5  0xb7f49c20 in zend_shutdown (tsrm_ls=0x804f0a0) 
> at /home/comp/rpm/BUILD/php-5.0.4/Zend/zend.c:714 
> #6  0xb7ef42d5 in php_module_shutdown 
(tsrm_ls=0x804f0a0) 
> at /home/comp/rpm/BUILD/php-5.0.4/main/main.c:1518 
> #7  0x0804be1e in main (argc=2, argv=0xb174) 
> 
at /home/comp/rpm/BUILD/php-5.0.4/sapi/cli/php_cli.c:1055 
> (gdb) f 1 
> #1  0xb7f557da in plist_entry_destructor (ptr=0x81e11b8) 
> 
at /home/comp/rpm/BUILD/php-5.0.4/Zend/zend_list.c:204 
> 204 
ld->plist_dtor_ex(le TSRMLS_CC); 
> (gdb) p ld->plist_dtor_ex 
> $1 = 0xb78a6978 
> (gdb) x ld->plist_dtor_ex 
> 0xb78a6978: Cannot access memory at address 
0xb78a6978 
 
it's in (unloaded) php-mysql module 
 
> The list here is "persistent_list", which is used by 
php-mysql for 
> persistent connection - so it's probably bug in 
php-mysql module or php 
> engine itself. 





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


#32751 [Opn]: Segfault after code execution (destructor calls)

2005-04-19 Thread tony2001
 ID:   32751
 Updated by:   [EMAIL PROTECTED]
 Reported By:  prism at pld-linux dot org
 Status:   Open
 Bug Type: Zend Engine 2 problem
 Operating System: PLD Linux Distribution
 PHP Version:  5.0.4
 New Comment:

Works fine on SuSE 9.2/glibc 2.3.3. 
I'm 100% sure it also works on other systems I have around here, but
I'll check it tomorrow.


Previous Comments:


[2005-04-19 22:37:43] prism at pld-linux dot org

I did't try in other OS. Later, I'll see in Windows - but 
I have to set up the environment first. 
Yes. I used glibc 2.3.4 before, and switched to 2.3.5 to 
see if it helps. 
It also happened earlier, when I had some older glibc, but 
I ignored it. 
The code also fails in CLI. Actually, we test it in CLI 
because Apache doesn't get any output from PHP module 
since it dies - proxy says that zero-sized reply comes. 
And finally: Yes, we build as much we can as modules to 
package it into separate packages.



[2005-04-19 22:23:38] [EMAIL PROTECTED]

Are you able to reproduce it under a different OS?
Or at least with different glibc?
Is it reproducible only with Apache2 or with CLI too?
As far as I can see, mysql is built as shared module or am I wrong?



[2005-04-19 21:20:11] prism at pld-linux dot org

What else do you need? You have been given exact cause and 
explanation what to fix. Let me know if we can still give 
you some more information.



[2005-04-19 08:51:00] [EMAIL PROTECTED]

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

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

Thank you for your interest in PHP.






[2005-04-18 21:49:05] prism at pld-linux dot org

Description:

Zend engine or all modules which use persistent_list. 
persistent_list is destroyed after modules are unloaded. 
But some modules register own destructors for elements put 
on 
persistent_list. When Zend destroys such entry from 
persistent_list, 
it tries to call destructor from unloaded module and 
segfaults. 

Reproduce code:
---
Look here: http://comments.gmane.org/gmane.linux.pld.devel.english/785
and start reading from post written at 16 Apr 17:33 by Michal Lukaszek,
and below from that.

Expected result:

No segfault. 

Actual result:
--
> (gdb) bt 
> #0  0xb78a6978 in ?? () 
> #1  0xb7f557da in plist_entry_destructor (ptr=0x81e11b8) 
> 
at /home/comp/rpm/BUILD/php-5.0.4/Zend/zend_list.c:204 
> #2  0xb7f5385f in zend_hash_apply_deleter (ht=0x8052c50, 
p=0x81ec1a0) 
> 
at /home/comp/rpm/BUILD/php-5.0.4/Zend/zend_hash.c:574 
> #3  0xb7f53ab0 in zend_hash_graceful_reverse_destroy 
(ht=0x8052c50) 
> 
at /home/comp/rpm/BUILD/php-5.0.4/Zend/zend_hash.c:640 
> #4  0xb7f558f6 in zend_destroy_rsrc_list (ht=0x8052c50, 
tsrm_ls=0x804f0a0) 
> 
at /home/comp/rpm/BUILD/php-5.0.4/Zend/zend_list.c:234 
> #5  0xb7f49c20 in zend_shutdown (tsrm_ls=0x804f0a0) 
> at /home/comp/rpm/BUILD/php-5.0.4/Zend/zend.c:714 
> #6  0xb7ef42d5 in php_module_shutdown 
(tsrm_ls=0x804f0a0) 
> at /home/comp/rpm/BUILD/php-5.0.4/main/main.c:1518 
> #7  0x0804be1e in main (argc=2, argv=0xb174) 
> 
at /home/comp/rpm/BUILD/php-5.0.4/sapi/cli/php_cli.c:1055 
> (gdb) f 1 
> #1  0xb7f557da in plist_entry_destructor (ptr=0x81e11b8) 
> 
at /home/comp/rpm/BUILD/php-5.0.4/Zend/zend_list.c:204 
> 204 
ld->plist_dtor_ex(le TSRMLS_CC); 
> (gdb) p ld->plist_dtor_ex 
> $1 = 0xb78a6978 
> (gdb) x ld->plist_dtor_ex 
> 0xb78a6978: Cannot access memory at address 
0xb78a6978 
 
it's in (unloaded) php-mysql module 
 
> The list here is "persistent_list", which is used by 
php-mysql for 
> persistent connection - so it's probably bug in 
php-mysql module or php 
> engine itself. 





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


#32767 [Opn->Bgs]: oracle connection not closing correctly

2005-04-20 Thread tony2001
 ID:   32767
 Updated by:   [EMAIL PROTECTED]
 Reported By:  daniel at bitarts dot com
-Status:   Open
+Status:   Bogus
 Bug Type: DBX related
 Operating System: solaris
 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.

See bug #32361.


Previous Comments:


[2005-04-19 14:19:59] daniel at bitarts dot com

Description:

Dozens of connection threads are being created in oracle. They aren't
being removed.

Using Oracle 9, Apache 2 

Reproduce code:
---
$link = dbx_connect ("oci8","","db","username","password")  
or
die("Can't connect");


$result = dbx_close($link) or die ("Can't close");

Expected result:

Nothing, no die messages reported.

Actual result:
--
"Can't close"





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


#32773 [Opn->Asn]: binary GMP functions returns unexpected value, when second parameter is int(0)

2005-04-21 Thread tony2001
 ID:   32773
 Updated by:   [EMAIL PROTECTED]
 Reported By:  valyala at gmail dot com
-Status:   Open
+Status:   Assigned
 Bug Type: Math related
 Operating System: unix
 PHP Version:  5.0.4
-Assigned To:  
+Assigned To:  stas
 New Comment:

Assigning to the maintainer.


Previous Comments:


[2005-04-19 22:32:25] valyala at gmail dot com

Description:

All binary functions from GMP extension return FALSE insted of expected
value, when zero is passed as second parameter.

I noticed the following piece of code in two places of ext/gmp/gmp.c
file, which purpose I couldn't understand:

if (!Z_LVAL_PP(b_arg)) {
RETURN_FALSE;
}

This code returns FALSE, when second parameter of binary GMP function
equals to zero.
I tried to delete this code from ext/gmp/gmp.c , and it seems that all
work nice after that.

Here is unified diff:
--cut--
--- gmp_old.c   Tue Apr 19 23:18:06 2005
+++ gmp.c   Tue Apr 19 23:18:28 2005
@@ -312,10 +312,6 @@
 FETCH_GMP_ZVAL(gmpnum_b, b_arg);
 }
 
-if (!Z_LVAL_PP(b_arg)) {
-RETURN_FALSE;
-}
-
 INIT_GMP_NUM(gmpnum_result);
 
 if (use_ui && gmp_ui_op) {
@@ -355,10 +351,6 @@
 use_ui = 1;
 } else {
 FETCH_GMP_ZVAL(gmpnum_b, b_arg);
-}
-
-if (!Z_LVAL_PP(b_arg)) {
-RETURN_FALSE;
 }
 
 INIT_GMP_NUM(gmpnum_result1);
--cut--


Reproduce code:
---


Expected result:

10 + 0 = 10
10 + 0 = 10


Actual result:
--
10 + 0 = 0
10 + 0 = 10






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


#32596 [Opn->Ver]: Segfault/Memory Leak by getClass (etc) in __destruct

2005-04-21 Thread tony2001
 ID:   32596
 Updated by:   [EMAIL PROTECTED]
 Reported By:  mailfrom-bugs dot php dot net at kopka dot net
-Status:   Open
+Status:   Verified
-Bug Type: Reproducible crash
+Bug Type: Zend Engine 2 problem
 Operating System: Linux (Gentoo)
 PHP Version:  5CVS-2005-04-05 (dev)
 New Comment:

It doesn't matter which function you use there.
I get the same result with $c=substr('qeqwe',3); instead of
$c=get_class($this);



Previous Comments:


[2005-04-19 00:51:29] mailfrom-bugs dot php dot net at kopka dot net

PHP-5.1.0-dev (build Apr 10 2005) is free of this problem.



[2005-04-05 20:09:19] mailfrom-bugs dot php dot net at kopka dot net

Description:

getClass($this) and others segfault or leak memory (when
--enable-debug) on 
PHP 5.0.3
PHP 5.0.4
PHP 5.0.5-dev (cli) (2005-04-05 11:42:27)
build on gentoo linux (default install flags).

I ran into this using the following construct:

if (database::query($string)->error) {}

where database::query() returns an object wrapping a result set (or
providing info on success of the request).

PHP 5.0.3 (and i am quite sure this applies to other versions as well
as i experience this for quite a time) segfaults under the following
cumulating circumstances:
- If the object is only used once and not referenced to a variable
- If a property is read/set (if a function is called all is OK)
- If __destruct references the class name by some means (others are
OK)

When you try the demo uncomment one of the lines which cause a segfault
(and are noted as a memory leak with --enable-debug):

//  $c=get_class($this);unset ($c);
//  echo get_class($this);
//  if(defined('DEBUG_'.__CLASS__)){}

The following lines don't raise a segfault:

  $c=__CLASS__;unset($c);
  if(__CLASS__ == "BUG") {};
  get_class($this);
  echo __CLASS__;

The following line don't raise a segfault but is noted as a memory leak
(--enable-debug):

  $c=get_class($this);

Naturally the hidden beast came up a long time after i wrote the line -
spending a good month of free time trying to locate it i am happy to
finally nail it to the ground for someone who knows what he is doing to
slay it (it cost me a keyboard and brought quite a few white hairs into
existence).

Since the original bug report vanished from the bug list (and can only
be found by number for reasons that escape me) i opened  it again (and
closed the other).

Good hunting.

Configure Command =>  './configure' '--prefix=/usr'
'--host=i686-pc-linux-gnu' '--mandir=/usr/share/man'
'--infodir=/usr/share/info' '--datadir=/usr/share' '--sysconfdir=/etc'
'--localstatedir=/var/lib' '--disable-cgi' '--enable-cli'
'--enable-embed' '--with-config-file-path=/etc/php/cli-php5'
'--disable-bcmath' '--without-bz2' '--disable-calendar'
'--without-cpdflib' '--disable-ctype' '--without-curl'
'--without-curlwrappers' '--disable-dbase' '--disable-dio'
'--disable-dom' '--disable-exif' '--without-fam' '--without-fbsql'
'--without-fdftk' '--disable-filepro' '--disable-ftp'
'--without-gettext' '--without-gmp' '--without-hwapi' '--without-iconv'
'--without-informix' '--without-ingres' '--without-interbase'
'--without-kerberos' '--disable-libxml' '--disable-mbstring'
'--without-mcrypt' '--without-mcve' '--disable-memory-limit'
'--without-mhash' '--without-mime-magic' '--without-ming'
'--without-mnogosearch' '--without-msql' '--without-mssql'
'--without-ncurses' '--without-oci8' '--without-oracle'
'--without-openssl' '--without-openssl-dir' '--without-ovrimos'
'--disable-pcntl' '--without-pcre-regx' '--without-pfpro'
'--without-pgsql' '--disable-posix' '--without-pspell'
'--without-recode' '--disable-simplexml' '--disable-shmop'
'--without-snmp' '--disable-soap' '--disable-sockets' '--disable-spl'
'--without-sybase' '--without-sybase-ct' '--disable-sysvmsg'
'--disable-sysvsem' '--disable-sysvshm' '--without-tidy'
'--disable-tokenizer' '--disable-wddx' '--without-xsl'
'--without-xmlrpc' '--disable-yp' '--without-zlib' '--disable-debug'
'--without-jpeg-dir' '--without-freetype-dir' '--without-t1lib'
'--without-ttf' '--disable-gd-jis-conf' '--disable-gd-native-ttf'
'--without-png-dir' '--without-tiff-dir' '--without-xpm-dir'
'--without-gd' '--disable-session' '--without-sqlite' '--disable-dba'
'--without-readline' '--without-libedit'


Reproduce code:
---
error;
  }
}

BUG::instance()->error;
echo "this is still executed\n";

?>

Expected result:

Expected result:

# php -n bug.php(cr)
please fix this thing, it wasted a nice part of my life!
this is still executed
# (cursor)

Actual result:
--
Sorry that i can not provide a core dump according to the requested
standards (vith --enable-debug) because if i compile like this there
is
no segfault (just a memory leak), so i hope a standard one will help:
--

#32789 [Opn->Fbk]: array_pop doesn't work correctly

2005-04-21 Thread tony2001
 ID:   32789
 Updated by:   [EMAIL PROTECTED]
 Reported By:  php at thoftware dot de
-Status:   Open
+Status:   Feedback
-Bug Type: Compile Failure
+Bug Type: Arrays related
 Operating System: Windows
 PHP Version:  4.3.9
 New Comment:

Please fill in expected & actual results fields.


Previous Comments:


[2005-04-21 14:59:37] php at thoftware dot de

Description:

array_pop() removes data from objects via a method.

Reproduce code:
---
class foobar { 
  var $cache = array(); 
  function cache($j) { 
if (!isset($this->cache[$j])) { 
  $this->cache[$j] = array( 
'wert' => $j, 
'text' => 'value: '.$j.'', 
'time' => 'set at '.date('h:i:s').'', 
  ); 
} 
return($this->cache[$j]); 
  } 
} 
$foobar =& new foobar(); 
$v = $foobar->cache(3); 
echo $v['time']; 
$v = $foobar->cache(3); 
echo $v['time']; 
$v = $foobar->cache(3); 
echo $v['time']; 
$v = $foobar->cache(3); 
echo $v['time']; 
/* returns as expected
  set at 02:19:11
  set at 02:19:11
  set at 02:19:11
  set at 02:19:11
*/ 
$foobar =& new foobar(); 
echo array_pop($foobar->cache(3)); 
/* returns as desired
  set at 02:19:11
*/ 
$foobar =& new foobar(); 
echo array_pop($foobar->cache(3)); 
echo array_pop($foobar->cache(3)); 
echo array_pop($foobar->cache(3)); 
echo array_pop($foobar->cache(3)); 
/* returns as not desired
  set at 02:19:11
  value: 3
  3 

*/ 
$foobar =& new foobar(); 
$v = $foobar->cache(3); 
echo $v['time']; 
echo array_pop($foobar->cache(3)); 
/* returns as it should
  set at 02:19:11

  Fatal error: Only variables can be passed by reference in ... 
*/ 
Seems that the first call with a method isn't recognized as being not a
variable =8-0.

Expected result:

see above

Actual result:
--
see above





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


#32789 [Opn->Fbk]: array_pop doesn't work correctly

2005-04-21 Thread tony2001
 ID:   32789
 Updated by:   [EMAIL PROTECTED]
 Reported By:  php at thoftware dot de
-Status:   Open
+Status:   Feedback
 Bug Type: Arrays related
 Operating System: Windows
 PHP Version:  4.3.9
 New Comment:

Then please explain the problem more clearly because the code you gave
is not understandable.
The main questions are:
what did you expect?
what did you get?

Also, please try newer version before reporting (the latest 4.3.x
version ATM is 4.3.11).


Previous Comments:


[2005-04-21 15:21:44] php at thoftware dot de

As there are 4 code-sniplets with 4 different results, I thought it
would be a good idea to show the results as comments with the
corresponding code. I don't think it would be more readable otherwise.



[2005-04-21 15:11:00] [EMAIL PROTECTED]

Please fill in expected & actual results fields.



[2005-04-21 14:59:37] php at thoftware dot de

Description:

array_pop() removes data from objects via a method.

Reproduce code:
---
class foobar { 
  var $cache = array(); 
  function cache($j) { 
if (!isset($this->cache[$j])) { 
  $this->cache[$j] = array( 
'wert' => $j, 
'text' => 'value: '.$j.'', 
'time' => 'set at '.date('h:i:s').'', 
  ); 
} 
return($this->cache[$j]); 
  } 
} 
$foobar =& new foobar(); 
$v = $foobar->cache(3); 
echo $v['time']; 
$v = $foobar->cache(3); 
echo $v['time']; 
$v = $foobar->cache(3); 
echo $v['time']; 
$v = $foobar->cache(3); 
echo $v['time']; 
/* returns as expected
  set at 02:19:11
  set at 02:19:11
  set at 02:19:11
  set at 02:19:11
*/ 
$foobar =& new foobar(); 
echo array_pop($foobar->cache(3)); 
/* returns as desired
  set at 02:19:11
*/ 
$foobar =& new foobar(); 
echo array_pop($foobar->cache(3)); 
echo array_pop($foobar->cache(3)); 
echo array_pop($foobar->cache(3)); 
echo array_pop($foobar->cache(3)); 
/* returns as not desired
  set at 02:19:11
  value: 3
  3 

*/ 
$foobar =& new foobar(); 
$v = $foobar->cache(3); 
echo $v['time']; 
echo array_pop($foobar->cache(3)); 
/* returns as it should
  set at 02:19:11

  Fatal error: Only variables can be passed by reference in ... 
*/ 
Seems that the first call with a method isn't recognized as being not a
variable =8-0.

Expected result:

see above

Actual result:
--
see above





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



#32791 [Opn->Fbk]: It cannot redeclare a function that has only been declared once.

2005-04-21 Thread tony2001
 ID:   32791
 Updated by:   [EMAIL PROTECTED]
 Reported By:  MIKEYTF at aol dot com
-Status:   Open
+Status:   Feedback
 Bug Type: *General Issues
 Operating System: Windows 98
 PHP Version:  4.3.9
 New Comment:

Thank you for this bug report. To properly diagnose the problem, we
need a short but complete example script to be able to reproduce
this bug ourselves. 

A proper reproducing script starts with ,
is max. 10-20 lines long and does not require any external 
resources such as databases, etc.

If possible, make the script source available online and provide
an URL to it here. Try to avoid embedding huge scripts into the report.

Please check that you don't have any of zend_extension's loaded.


Previous Comments:


[2005-04-21 16:52:52] MIKEYTF at aol dot com

Description:

Well, I created a function sys_msg($error,$exit).  Then it says "Cannot
redeclare sys_msg() (previously declared in cfg.inc.php on line 44) on
line 44".  It does not make sense!

Reproduce code:
---
Well, I don't think I need to show a source code because it is just a
function..  but here is the error page:  http://subzer0.net/reloaded/

Expected result:

I expect the index to load and for it to give me an error telling me
that some SQL tables are missing.  (I haven't completed all the SQL)

Actual result:
--
It gives me the "cannot redeclare" error. 
(http://subzer0.net/reloaded)





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


#32791 [Opn->Fbk]: It cannot redeclare a function that has only been declared once.

2005-04-21 Thread tony2001
 ID:   32791
 Updated by:   [EMAIL PROTECTED]
 Reported By:  MIKEYTF at aol dot com
-Status:   Open
+Status:   Feedback
 Bug Type: *General Issues
 Operating System: Windows 98
 PHP Version:  4.3.9
 New Comment:

Again, please check that you don't have any of zend_extensions like
MMCache, ionCube, Zend Optimizer etc.

And your code works fine with all the latest 5.1, 5.0.x & 4.3.x
versions .


Previous Comments:


[2005-04-21 17:26:07] MIKEYTF at aol dot com








That's the shortest script I could make..



[2005-04-21 17:19:58] [EMAIL PROTECTED]

How can we test if we don't know what to test?
Create the shortest possible test script you can
and add it here.




[2005-04-21 17:13:05] MIKEYTF at aol dot com

You want me to give you guys the function so you could try it out
yourselves?



[2005-04-21 17:00:56] [EMAIL PROTECTED]

Thank you for this bug report. To properly diagnose the problem, we
need a short but complete example script to be able to reproduce
this bug ourselves. 

A proper reproducing script starts with ,
is max. 10-20 lines long and does not require any external 
resources such as databases, etc.

If possible, make the script source available online and provide
an URL to it here. Try to avoid embedding huge scripts into the report.

Please check that you don't have any of zend_extension's loaded.



[2005-04-21 16:52:52] MIKEYTF at aol dot com

Description:

Well, I created a function sys_msg($error,$exit).  Then it says "Cannot
redeclare sys_msg() (previously declared in cfg.inc.php on line 44) on
line 44".  It does not make sense!

Reproduce code:
---
Well, I don't think I need to show a source code because it is just a
function..  but here is the error page:  http://subzer0.net/reloaded/

Expected result:

I expect the index to load and for it to give me an error telling me
that some SQL tables are missing.  (I haven't completed all the SQL)

Actual result:
--
It gives me the "cannot redeclare" error. 
(http://subzer0.net/reloaded)





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


#32793 [Opn->Bgs]: foreach chage the type from object to string

2005-04-21 Thread tony2001
 ID:   32793
 Updated by:   [EMAIL PROTECTED]
 Reported By:  ijb_green at hotmail dot com
-Status:   Open
+Status:   Bogus
 Bug Type: Class/Object related
 Operating System: Linux  2.6.9-1.667
 PHP Version:  4.3.10
 New Comment:

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




Previous Comments:


[2005-04-21 22:10:13] ijb_green at hotmail dot com

Description:

When i iterate a array that contains Objects asociated with a numeric
key  foreach statement changes the type of the variable from object to
string then i can't access to the object methods but i can acces to its
attributes. 

Reproduce code:
---
foreach ($Resultados as $Clave=>$Objeto){
if($Clave!="Count" ||$Clave!="LegislaturaRomano"){
printf("%s",$Objeto->denomiCorta);
//Access to the object attribute

printf("%s",//access object's method here
it fails
$Objeto->getTotalInicitivasDictaminadas());

...

Expected result:

Display the result of the method getTotalInicitivasDictaminadas it only
adds two values

Actual result:
--
Fatal error: Call to a member function on a non-object 





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


#32750 [Csd->Bgs]: pg_escape_string removes some backslashes

2005-04-21 Thread tony2001
 ID:   32750
 Updated by:   [EMAIL PROTECTED]
 Reported By:  master-bx at users dot sourceforge dot net
-Status:   Closed
+Status:   Bogus
 Bug Type: PostgreSQL related
 Operating System: Windows XP SP2
 PHP Version:  5.0.4
 New Comment:

No bug -> bogus.


Previous Comments:


[2005-04-21 23:31:36] master-bx at users dot sourceforge dot net

done



[2005-04-21 23:31:10] master-bx at users dot sourceforge dot net

The bug can be closed, my mistake. variable must be first set to static
an then defined. that caused the error. nevertheless thanks for help.



[2005-04-21 20:22:47] master-bx at users dot sourceforge dot net

yes, here is my mysql testing code:

($var);
}
?>

<> = mysql(i)_real_escape_string or pg_escape_string

mysql works, mysqli and pg not, but i found a typo in a function that
uses this one. i will go on testing ...



[2005-04-21 14:38:12] [EMAIL PROTECTED]

Have you read this manual page very carefully:

http://www.php.net/mysql_real_escape_string

Especially the part about magic_quotes..(the example too)




[2005-04-20 23:16:14] master-bx at users dot sourceforge dot net

Parse error: syntax error, unexpected $end in
***\Apache2\htdocs\test.php on line 6

So my example has been wrong, sorry. Tried it with '\ \\ ' and got
the following:

string(6) '\ \ \\' string(10) '\\ \\ '

So it does well, but ...

to better describe my problem: mysql_real_escape_string does it another
way, because it handles POST-data correct for database-storage.
pg_escape_string and mysqli_real_escape_string are cutting some \ and i
don't get the data stored like the input cames from POST. do you
understand it now or need a larger example?



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

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


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

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

Please try using this CVS snapshot:

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




Previous Comments:


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

I have this behaviour with the following scenario:

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



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

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

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



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

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



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

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



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

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



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

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


#30002 [Asn]: Undefined property notice appear when __get method access $this->OtherProperty

2005-04-22 Thread tony2001
 ID:   30002
 Updated by:   [EMAIL PROTECTED]
 Reported By:  orlum at mail dot ru
 Status:   Assigned
 Bug Type: Zend Engine 2 problem
 Operating System: *
 PHP Version:  5CVS-2005-03-07
 Assigned To:  andi
 New Comment:

I really doubt that it's a bug because if we allow calling __get() from
__get() you'll get into endless loop easily, which is of course much
worse than just a notice.
Take a look into zend_std_read_property() (in zend_object_handlers.c),
there is simple loop protection.
So I'd prefer more to see this documented than fixed in some way.


Previous Comments:


[2005-02-12 18:06:30] imperior at op dot pl

Another exaple, where IMHO it should work:
objects[$name])) {
$this->objects[$name] = new $name($this);
}
return $this->objects[$name];
}

}

class Class1 {
public function __construct($Creat) {
echo 'Class1';
$Creat->Class2;
}
}

class Class2 {
public function __construct($Creat) {
echo 'Class2';
}
}

$Creat = new Creator;
$Creat->Class1;
?>

OUTPUT:
Class1
Notice: Undefined property: Creator::$Class2 in
D:\Server\www\noname\test.php on line 17

Expected:
Class1Class2



[2004-09-06 21:46:32] [EMAIL PROTECTED]

Interesting thing:

1) It should happen at all because using $this->B should result in an
implicitly declared proeprty.

2) It is expected behavior because __get/__set have a simple recursion
protection which disables __get/__set during __get/__set calls.



[2004-09-06 18:51:46] orlum at mail dot ru

Description:

When __get method accesses other property in some class, expected call
to __get method not occurs, undefined property notice appears and null
value of property returns.

Reproduce code:
---
B;
}
}


error_reporting(E_ALL);

$a = new A();
echo "B={$a->B}\n";
echo "C={$a->C}\n";


?>

Expected result:

__get()
B=1
__get()
__get()
C=1


Actual result:
--
__get()
B=1
__get()
Notice:  Undefined property:  A::$B in PHPDocument1 on line 12
C=






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


#28883 [Opn->Asn]: [PATCH] fix for crash during module shutdown

2005-04-22 Thread tony2001
 ID:   28883
 Updated by:   [EMAIL PROTECTED]
 Reported By:  novicky at aarongroup dot cz
-Status:   Open
+Status:   Assigned
 Bug Type: Informix related
 Operating System: *
 PHP Version:  4CVS, 5CVS (2005-02-05)
-Assigned To:  
+Assigned To:  nobbie


Previous Comments:


[2004-06-22 19:08:12] novicky at aarongroup dot cz

Description:

There is a problem in function ifx_do_close which can lead to crash
during module shutdown.
The function ifx_do_close is called during shutdown from list
destrucors _close_ifx_link and _close_ifx_plink. If something goes
wrong in this function, error reporting is performed and emalloc is
called. Calling emalloc is not possible during memory destruction and
can cause segfault.
It is necessary to remove all error reporting from ifx_do_close (which
is in fact useless).

Here is a patch:

--- ifx.ec.orig 2004-06-01 02:52:14.0 +0200
+++ ifx.ec  2004-06-22 18:46:01.0 +0200
@@ -295,7 +295,6 @@
PARAMETER char *link;
 EXEC SQL END DECLARE SECTION;
 {
-   char *ifx_err = NULL;
TSRMLS_FETCH();
 
EXEC SQL SET CONNECTION :link;
@@ -310,32 +309,12 @@
if (ifx_check() == 0)   {
/* DISCONNECT again, after rollback */
EXEC SQL DISCONNECT :link;
-   if (ifx_check() < 0)   {
-   IFXG(sv_sqlcode) = SQLCODE;
-   php_error_docref(NULL TSRMLS_CC, 
E_WARNING, "Disconnect link %s
after Automatic Rollback fails (%s)", link, (ifx_err =
ifx_error(link)));
}
-   }
-   if (ifx_check() < 0)   {
+   else if (ifx_check() < 0)   {
/* CLOSE database if rollback or disconnect 
fails */
EXEC SQL CLOSE DATABASE;
-   if (ifx_check() < 0)   {
-   IFXG(sv_sqlcode) = SQLCODE;
-   php_error_docref(NULL TSRMLS_CC, 
E_WARNING, "Close database fails
%s (%s)", link, (ifx_err = ifx_error(link)));
-   }
}
}
-   else if (SQLCODE < 0)   {
-   IFXG(sv_sqlcode) = SQLCODE;
-   php_error_docref(NULL TSRMLS_CC, E_WARNING, "Disconnect 
link %s
fails (%s)", link, (ifx_err = ifx_error(link)));
-   }
-   }   
-   else   {
-   IFXG(sv_sqlcode) = SQLCODE;
-   php_error_docref(NULL TSRMLS_CC, E_WARNING, "Set connection %s 
fails
(%s)", link, (ifx_err = ifx_error(link)));
-   }
-
-   if (ifx_err) {
-   efree(ifx_err);
}
 }
 








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


#26456 [Ver]: Wrong results from Reflection-API getDocComment() when called via STDIN

2005-04-22 Thread tony2001
 ID:   26456
 Updated by:   [EMAIL PROTECTED]
 Reported By:  schlueter at phpbar dot de
 Status:   Verified
 Bug Type: Zend Engine 2 problem
 Operating System: linux
 PHP Version:  5CVS-2004-03-15
 New Comment:

Seems like a compiler problem to me.
That's what I got when running the script via STDIN:

1314if (fptr->type == ZEND_USER_FUNCTION &&
fptr->op_array.doc_comment) {
(gdb) p fptr->op_array.doc_comment
$1 = 0x82ce2dc "\n  function increment"

If the script is run via `php script.php` fptr->op_array.doc_comment
contains expected value (i.e. the comment itself, without any garbage
data).


Previous Comments:


[2003-11-30 04:28:55] [EMAIL PROTECTED]

Thank you for the explanation. (I've never ever run scripts like this
:). Verified..and here's short example script to test this:

getDocComment();
  echo "\n--\n";

?>

Bad output (with "# php  && paste script && ctrl+d):
--

  function increment)

   *
   * @access  public
   * @return  int
   */
--

Good output:
--
/**
   * Increment counter
   *
   * @access  public
   * @return  int
   */
--




[2003-11-29 09:15:15] schlueter at phpbar dot de

I've tested now with php5-200311291230 (simply ./configure without any
paramters) and get the same results. And the exact way I'm runnig PHP
ist this:

1. I'm opening a shell window
2. $ ./php [return]
3. I put the source into the clipboard
4. I paste it into the shell window
5. Ctrl+D
6. Wrong results (see original report) appear

I hope now it's clear how I'm doing it.
I've just tested it on another Linux machine: Same results...



[2003-11-28 20:32:22] [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 show exactly HOW you run it when it doesn't work,






[2003-11-28 17:07:52] schlueter at phpbar dot de

Description:

While testing the examples from
http://sitten-polizei.de/php/reflection_api/docs/language.reflection.html
I found a (for me) unexpected beahvior with
Reflection_Function::getDocComment() and
Reflection_Method::getDocComment() the  when calling PHP on the command
line without paramter and copying a test script into my shell window, so
PHP can read it from STDIN. If I call the same script from a file or
pipe (cat test.php | /opt/php5/bin/php) all seems to work.

Reproduce code:
---
Example 14-5 from
http://sitten-polizei.de/php/reflection_api/docs/language.reflection.class.reflection_method.html

Expected result:

===> The user-defined final public static method 'increment' (which is
a regular method)
 declared in -
 lines 13 to 17
 having the modifiers 261[final public static]
---> Documentation:
 '/**
   * Increment counter
   *
   * @final
   * @static
   * @access  public
   * @return  int
   */'
---> Invokation results in: int(1)

Actual result:
--
===> The user-defined final public static method 'increment' (which is
a regular method)
 declared in /home/johannes/-
 lines 13 to 17
 having the modifiers 261[final public static]
---> Documentation:
 '
  final public static function increment)
final
   * @static
   * @access  public
   * @return  int
   */'
---> Invokation results in: int(1)





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


#32804 [Opn->Bgs]: timestamp april's wrong result

2005-04-23 Thread tony2001
 ID:   32804
 Updated by:   [EMAIL PROTECTED]
 Reported By:  ygomez at hotmail dot com
-Status:   Open
+Status:   Bogus
-Bug Type: Date/time related
+Bug Type: *General Issues
 Operating System: Win (xp, 2k)
 PHP Version:  4.3.10
 New Comment:

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




Previous Comments:


[2005-04-23 18:28:25] ygomez at hotmail dot com

Description:

This error only came about in April 2005 at 2:00. I got 1 hr missing on
timestamp result and affect the following timestamp's results.

I hope can help me.

Reproduce code:
---



Expected result:

1112508000
1112511600
1112515200
1112594400


Actual result:
--
1112508000
1112511600
1112511600
1112590800






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


#32794 [Ctl->Asn]: install-pear.php segfaults (ZE2 bug)

2005-04-23 Thread tony2001
 ID:   32794
 Updated by:   [EMAIL PROTECTED]
 Reported By:  benjcarson at digitaljunkies dot ca
-Status:   Critical
+Status:   Assigned
 Bug Type: Reproducible crash
 Operating System: *
 PHP Version:  5CVS-2005-04-21 (dev)
-Assigned To:  
+Assigned To:  helly
 New Comment:

Assigning to Marcus, he broke it.

See the patch below:

Index: zend_compile.c
===
RCS file: /repository/ZendEngine2/zend_compile.c,v
retrieving revision 1.618
diff -u -p -d -r1.618 zend_compile.c
--- zend_compile.c  19 Apr 2005 22:04:57 -  1.618
+++ zend_compile.c  24 Apr 2005 00:14:24 -
@@ -42,6 +42,7 @@ ZEND_API zend_executor_globals executor_
 static void zend_duplicate_property_info(zend_property_info
*property_info)
 {
property_info->name = estrndup(property_info->name,
property_info->name_length);
+   property_info->doc_comment =
estrndup(property_info->doc_comment, property_info->doc_comment_len);
 }



Previous Comments:


[2005-04-21 23:02:52] benjcarson at digitaljunkies dot ca

Description:

The latest (2005-04-21) CVS HEAD and snaps are segfaulting while
executing install-pear.php during make install.  Here's a backtrace:

#0  0x407b8e84 in mallopt () from /lib/tls/libc.so.6
#1  0x407b7dcb in free () from /lib/tls/libc.so.6
#2  0x0818a692 in _efree (ptr=0x832951c) at
/usr/src/php5-200504211030/Zend/zend_alloc.c:308
#3  0x081a4f38 in zend_hash_destroy (ht=0x83c1b50) at
/usr/src/php5-200504211030/Zend/zend_hash.c:519
#4  0x081977b7 in destroy_zend_class (pce=0x10652d38) at
/usr/src/php5-200504211030/Zend/zend_opcode.c:161
#5  0x081a4e16 in zend_hash_del_key_or_index (ht=0x826f3d8,
arKey=0x84e0390 "pear_registry", nKeyLength=14, h=3284853093,
flag=0) at /usr/src/php5-200504211030/Zend/zend_hash.c:490
#6  0x081a540d in zend_hash_reverse_apply (ht=0x826f3d8,
apply_func=0x8193f20 )
at /usr/src/php5-200504211030/Zend/zend_hash.c:736
#7  0x0819461c in shutdown_executor () at
/usr/src/php5-200504211030/Zend/zend_execute_API.c:264
#8  0x0819e6d5 in zend_deactivate () at
/usr/src/php5-200504211030/Zend/zend.c:823
#9  0x08166db6 in php_request_shutdown (dummy=0x0) at
/usr/src/php5-200504211030/main/main.c:1217
#10 0x0820ecc0 in main (argc=2, argv=0xba04) at
/usr/src/php5-200504211030/sapi/cli/php_cli.c:1057


I've tried to narrow down the test case a little bit, see the reproduce
code below.

Reproduce code:
---


Expected result:

[no output]

Actual result:
--
Segmentation Fault





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


#32809 [Opn->Fbk]: t1lib + GD on Windows

2005-04-24 Thread tony2001
 ID:   32809
 Updated by:   [EMAIL PROTECTED]
 Reported By:  ng4rrjanbiah at rediffmail dot com
-Status:   Open
+Status:   Feedback
 Bug Type: GD related
 Operating System: Windows XP
 PHP Version:  5.0.4
 New Comment:

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

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

Thank you for your interest in PHP.





Previous Comments:


[2005-04-24 12:26:08] ng4rrjanbiah at rediffmail dot com

Description:

GD functions for example imagepsbbox(), imagepstext()--that depend on
t1lib doesn't work on Windows.

Where to download t1lib or gd dlls for that? The documentation is
incomplete and couldn't find how to run in Windows.

c.l.php regular Chris Hope says that he could be able to get it working
by compiling using Cygwin (
http://groups.google.com/[EMAIL PROTECTED] ).
What's the other way?

-R. Rajesh Jeba Anbiah






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


#32304 [Opn->Csd]: Invalid exception code hangs server thread.

2005-04-24 Thread tony2001
 ID:   32304
 Updated by:   [EMAIL PROTECTED]
 Reported By:  peter at letford dot co dot uk
-Status:   Open
+Status:   Closed
 Bug Type: Zend Engine 2 problem
 Operating System: Windows XP Professional
 PHP Version:  5CVS-2005-03-15
 New Comment:

Not reproducible anymore -> closed.


Previous Comments:


[2005-04-24 15:52:06] peter at letford dot co dot uk

I have just downloaded the latest snapshot and the bug appears to have
been fixed.

Thanks


Peter.



[2005-04-13 01:00:07] php-bugs at lists dot php dot net

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



[2005-04-05 10:11:46] [EMAIL PROTECTED]

Please try using this CVS snapshot:

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





[2005-03-26 19:41:49] peter at letford dot co dot uk

Hi there,

I have now installed the latest PHP 5 and Apache 1.3.33 on a clean
machine. Whilst the initial problem seems to have gone away the Apache
web server now crashes but I believe it's still a problem of PHP
because debug log mentions php5ts.dll saying the following:

szAppName: Apache.exe
szAppVer: 0.0.0.0
szModName: php5ts.dll
szModVer: 5.1.0.0
offset: 7c9e

An interesting fact that the offset is _allways_ the same. Although it
doesn't crash every time you run the example code (from original bug
report) holding refresh for a few seconds causes the problem
consistantly.

I have saved the memory dump of the program if you need it.



[2005-03-25 01:54:35] [EMAIL PROTECTED]

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





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

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


#32794 [Asn->Fbk]: install-pear.php segfaults (ZE2 bug)

2005-04-24 Thread tony2001
 ID:   32794
 Updated by:   [EMAIL PROTECTED]
 Reported By:  benjcarson at digitaljunkies dot ca
-Status:   Assigned
+Status:   Feedback
 Bug Type: Reproducible crash
 Operating System: *
 PHP Version:  5CVS-2005-04-21 (dev)
 Assigned To:  helly
 New Comment:

Please try using this CVS snapshot:

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




Previous Comments:


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

Assigning to Marcus, he broke it.

See the patch below:

Index: zend_compile.c
===
RCS file: /repository/ZendEngine2/zend_compile.c,v
retrieving revision 1.618
diff -u -p -d -r1.618 zend_compile.c
--- zend_compile.c  19 Apr 2005 22:04:57 -  1.618
+++ zend_compile.c  24 Apr 2005 00:14:24 -
@@ -42,6 +42,7 @@ ZEND_API zend_executor_globals executor_
 static void zend_duplicate_property_info(zend_property_info
*property_info)
 {
property_info->name = estrndup(property_info->name,
property_info->name_length);
+   property_info->doc_comment =
estrndup(property_info->doc_comment, property_info->doc_comment_len);
 }




[2005-04-21 23:02:52] benjcarson at digitaljunkies dot ca

Description:

The latest (2005-04-21) CVS HEAD and snaps are segfaulting while
executing install-pear.php during make install.  Here's a backtrace:

#0  0x407b8e84 in mallopt () from /lib/tls/libc.so.6
#1  0x407b7dcb in free () from /lib/tls/libc.so.6
#2  0x0818a692 in _efree (ptr=0x832951c) at
/usr/src/php5-200504211030/Zend/zend_alloc.c:308
#3  0x081a4f38 in zend_hash_destroy (ht=0x83c1b50) at
/usr/src/php5-200504211030/Zend/zend_hash.c:519
#4  0x081977b7 in destroy_zend_class (pce=0x10652d38) at
/usr/src/php5-200504211030/Zend/zend_opcode.c:161
#5  0x081a4e16 in zend_hash_del_key_or_index (ht=0x826f3d8,
arKey=0x84e0390 "pear_registry", nKeyLength=14, h=3284853093,
flag=0) at /usr/src/php5-200504211030/Zend/zend_hash.c:490
#6  0x081a540d in zend_hash_reverse_apply (ht=0x826f3d8,
apply_func=0x8193f20 )
at /usr/src/php5-200504211030/Zend/zend_hash.c:736
#7  0x0819461c in shutdown_executor () at
/usr/src/php5-200504211030/Zend/zend_execute_API.c:264
#8  0x0819e6d5 in zend_deactivate () at
/usr/src/php5-200504211030/Zend/zend.c:823
#9  0x08166db6 in php_request_shutdown (dummy=0x0) at
/usr/src/php5-200504211030/main/main.c:1217
#10 0x0820ecc0 in main (argc=2, argv=0xba04) at
/usr/src/php5-200504211030/sapi/cli/php_cli.c:1057


I've tried to narrow down the test case a little bit, see the reproduce
code below.

Reproduce code:
---


Expected result:

[no output]

Actual result:
--
Segmentation Fault





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


#32794 [Fbk->Csd]: install-pear.php segfaults (ZE2 bug)

2005-04-24 Thread tony2001
 ID:   32794
 Updated by:   [EMAIL PROTECTED]
 Reported By:  benjcarson at digitaljunkies dot ca
-Status:   Feedback
+Status:   Closed
 Bug Type: Reproducible crash
 Operating System: *
 PHP Version:  5CVS-2005-04-21 (dev)
 Assigned To:  helly
 New Comment:

Erm. Clicked wrong link.
I meant it's fixed in CVS.


Previous Comments:


[2005-04-24 19:40:41] [EMAIL PROTECTED]

Please try using this CVS snapshot:

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





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

Assigning to Marcus, he broke it.

See the patch below:

Index: zend_compile.c
===
RCS file: /repository/ZendEngine2/zend_compile.c,v
retrieving revision 1.618
diff -u -p -d -r1.618 zend_compile.c
--- zend_compile.c  19 Apr 2005 22:04:57 -  1.618
+++ zend_compile.c  24 Apr 2005 00:14:24 -
@@ -42,6 +42,7 @@ ZEND_API zend_executor_globals executor_
 static void zend_duplicate_property_info(zend_property_info
*property_info)
 {
property_info->name = estrndup(property_info->name,
property_info->name_length);
+   property_info->doc_comment =
estrndup(property_info->doc_comment, property_info->doc_comment_len);
 }




[2005-04-21 23:02:52] benjcarson at digitaljunkies dot ca

Description:

The latest (2005-04-21) CVS HEAD and snaps are segfaulting while
executing install-pear.php during make install.  Here's a backtrace:

#0  0x407b8e84 in mallopt () from /lib/tls/libc.so.6
#1  0x407b7dcb in free () from /lib/tls/libc.so.6
#2  0x0818a692 in _efree (ptr=0x832951c) at
/usr/src/php5-200504211030/Zend/zend_alloc.c:308
#3  0x081a4f38 in zend_hash_destroy (ht=0x83c1b50) at
/usr/src/php5-200504211030/Zend/zend_hash.c:519
#4  0x081977b7 in destroy_zend_class (pce=0x10652d38) at
/usr/src/php5-200504211030/Zend/zend_opcode.c:161
#5  0x081a4e16 in zend_hash_del_key_or_index (ht=0x826f3d8,
arKey=0x84e0390 "pear_registry", nKeyLength=14, h=3284853093,
flag=0) at /usr/src/php5-200504211030/Zend/zend_hash.c:490
#6  0x081a540d in zend_hash_reverse_apply (ht=0x826f3d8,
apply_func=0x8193f20 )
at /usr/src/php5-200504211030/Zend/zend_hash.c:736
#7  0x0819461c in shutdown_executor () at
/usr/src/php5-200504211030/Zend/zend_execute_API.c:264
#8  0x0819e6d5 in zend_deactivate () at
/usr/src/php5-200504211030/Zend/zend.c:823
#9  0x08166db6 in php_request_shutdown (dummy=0x0) at
/usr/src/php5-200504211030/main/main.c:1217
#10 0x0820ecc0 in main (argc=2, argv=0xba04) at
/usr/src/php5-200504211030/sapi/cli/php_cli.c:1057


I've tried to narrow down the test case a little bit, see the reproduce
code below.

Reproduce code:
---


Expected result:

[no output]

Actual result:
--
Segmentation Fault





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


#32812 [Opn->Fbk]: Post Multipart/formdata, $HTTP_POST_VARS doesn't get initialized correctly!

2005-04-24 Thread tony2001
 ID:   32812
 Updated by:   [EMAIL PROTECTED]
 Reported By:  samuel at replicon dot com
-Status:   Open
+Status:   Feedback
 Bug Type: Scripting Engine problem
 Operating System: Windows 2000
 PHP Version:  5.0.4
 New Comment:

Use var_dump($HTTP_POST_VARS); to see the contents of the variable.
Also check $_POST too.


Previous Comments:


[2005-04-24 21:58:41] samuel at replicon dot com

refine summary.



[2005-04-24 21:55:30] samuel at replicon dot com

Code to reproduce the bug
=









Choose a file to upload:








[2005-04-24 21:29:06] samuel at replicon dot com

Description:

when post multipart/form-data, $HTTP_POST_VARS doesn't get initialized
correctly, actually, it's empty.

Expected result:

$HTTP_POST_VARS should contain post data






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


#32812 [Opn->Fbk]: Post Multipart/formdata, $HTTP_POST_VARS doesn't get initialized correctly!

2005-04-24 Thread tony2001
 ID:   32812
 Updated by:   [EMAIL PROTECTED]
 Reported By:  samuel at replicon dot com
-Status:   Open
+Status:   Feedback
 Bug Type: Scripting Engine problem
 Operating System: Windows 2000
 PHP Version:  5.0.4
 New Comment:

Check that register_long_arrays is On.


Previous Comments:


[2005-04-24 22:16:51] samuel at replicon dot com

var_dump($_POST) --> array(1) { ["submit"]=> string(6) "submit" }



[2005-04-24 22:13:47] samuel at replicon dot com

var_dump($HTTP_POST_VARS) --> NULL
  var_dump($HTTP_POST_FILES) --> NULL



[2005-04-24 22:07:44] [EMAIL PROTECTED]

Use var_dump($HTTP_POST_VARS); to see the contents of the variable.
Also check $_POST too.



[2005-04-24 21:58:41] samuel at replicon dot com

refine summary.



[2005-04-24 21:55:30] samuel at replicon dot com

Code to reproduce the bug
=









Choose a file to upload:








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

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


#32812 [Csd->Bgs]: Post Multipart/formdata, $HTTP_POST_VARS doesn't get initialized correctly!

2005-04-24 Thread tony2001
 ID:   32812
 Updated by:   [EMAIL PROTECTED]
 Reported By:  samuel at replicon dot com
-Status:   Closed
+Status:   Bogus
 Bug Type: Scripting Engine problem
 Operating System: Windows 2000
 PHP Version:  5.0.4
 New Comment:

.


Previous Comments:


[2005-04-24 22:31:28] samuel at replicon dot com

Thanks, the Check that register_long_arrays is off. After turned it on,
everything is working now.



[2005-04-24 22:20:56] [EMAIL PROTECTED]

Check that register_long_arrays is On.



[2005-04-24 22:16:51] samuel at replicon dot com

var_dump($_POST) --> array(1) { ["submit"]=> string(6) "submit" }



[2005-04-24 22:13:47] samuel at replicon dot com

var_dump($HTTP_POST_VARS) --> NULL
  var_dump($HTTP_POST_FILES) --> NULL



[2005-04-24 22:07:44] [EMAIL PROTECTED]

Use var_dump($HTTP_POST_VARS); to see the contents of the variable.
Also check $_POST too.



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

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


#32815 [Opn->Bgs]: Problem with header() function

2005-04-24 Thread tony2001
 ID:   32815
 Updated by:   [EMAIL PROTECTED]
 Reported By:  webmaster at ebinformatique dot com
-Status:   Open
+Status:   Bogus
 Bug Type: HTTP related
 Operating System: Windows XP SP2
 PHP Version:  4.3.10
 New Comment:

Turn display_errors ON.


Previous Comments:


[2005-04-24 23:36:53] webmaster at ebinformatique dot com

I discovered there was 2 linebreaks in a file included before the
redirection.

But even with error_reporting(E_ALL) it did not send me warnings or
anything to the browser saying there was already some output generated.



[2005-04-24 23:16:57] webmaster at ebinformatique dot com

Description:

I have a problem with the header() function, it happened all off a
sudden:

Whenever there is a call to header() to redirect a page (i tried the
echo method in another bug report and this is the output it gave):

Location: http://192.168.1.100:99/members/logged_out.php

Whenever i do a redirection it points to a blank page, no source
visible whatsoever. I tried updating version from 4.3.10 to 4.3.11 but
no go, still same problem. But it was working fine so i hightly doubt
it could be the form of the URL itself to be the problem.

Cleared my browser cache too, nothing helped. Tried in IE, Firefox,
both with empty caches, same problem, i get a white page.


Reproduce code:
---
Here is a chunk of code that called a redirection function:

if ($tmp_bool_login) {
 Global_Functions::redirect_user($_POST['redirect']);
}

and the redirect_user:

function redirect_user($tmp_str_destination) {
 session_write_close();
 header('Location: ' . $tmp_str_destination);
 header('Content-Location: ' . $tmp_str_destination);
 header('Request-URI: ' . $tmp_str_destination);
 exit;
}


Expected result:

If the $tmp_bool_login was successful, it would redirect to
$_POST['redirect'] so that the user gets send back to the page he was
when he signed in. not a blank page.

Actual result:
--
When filling the form with a user and pass, it sends to login and it's
a success, but it fails to redirect to the page. In fact any
redirection whatsoever fails.





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


#32816 [Opn->Csd]: upload_max_filesize not working

2005-04-25 Thread tony2001
 ID:   32816
 Updated by:   [EMAIL PROTECTED]
 Reported By:  admin at seasoft dot nl
-Status:   Open
+Status:   Closed
 Bug Type: Unknown/Other Function
 Operating System: Freebsd 5.2.1
 PHP Version:  5.0.4
 New Comment:

This bug has been fixed in CVS.

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




Previous Comments:


[2005-04-25 02:16:35] admin at seasoft dot nl

Description:

Hi, i've upgraded to php 5.0.4 from 4.3.4 and while file downloads did
work on the old version, i'am having difficulties with the last version
when files are over 2MB in size. Files that are bigger are just cut
short.

Adjusting upload_max_filesize and post_max_size doesn't help although
the changes are visible when viewing phpinfo.

phpinfo can be found here:
http://seasoft.nl/info.php

The error logs remain silent.

Thanks,

Tjeerd



Reproduce code:
---








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


#32816 [Csd->Bgs]: upload_max_filesize not working

2005-04-25 Thread tony2001
 ID:   32816
 Updated by:   [EMAIL PROTECTED]
 Reported By:  admin at seasoft dot nl
-Status:   Closed
+Status:   Bogus
 Bug Type: Unknown/Other Function
 Operating System: Freebsd 5.2.1
 PHP Version:  5.0.4
 New Comment:

See #32553.


Previous Comments:


[2005-04-25 09:12:34] [EMAIL PROTECTED]

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.





[2005-04-25 02:16:35] admin at seasoft dot nl

Description:

Hi, i've upgraded to php 5.0.4 from 4.3.4 and while file downloads did
work on the old version, i'am having difficulties with the last version
when files are over 2MB in size. Files that are bigger are just cut
short.

Adjusting upload_max_filesize and post_max_size doesn't help although
the changes are visible when viewing phpinfo.

phpinfo can be found here:
http://seasoft.nl/info.php

The error logs remain silent.

Thanks,

Tjeerd



Reproduce code:
---








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


#32822 [Opn->Bgs]: filedownloading scripts stops sending data prematurely at 2.000.000 bytes

2005-04-25 Thread tony2001
 ID:   32822
 Updated by:   [EMAIL PROTECTED]
 Reported By:  stian dot stryni at online dot no
-Status:   Open
+Status:   Bogus
-Bug Type: Reproducible crash
+Bug Type: Filesystem function related
 Operating System: Fedora Core 2 2.6.9-1.6
 PHP Version:  5.0.4
 New Comment:

Search the bug database before reporting.
It's bug #32553 and it's already fixed in CVS.


Previous Comments:


[2005-04-25 10:41:02] stian dot stryni at online dot no

Description:

A script we use enabling users to download uploaded files from the
webserver uses readfile() to accomplish this task.

At 2.000.000 bytes the script always stops sending output without any
mention in any logs.

The behaviour started after upgrading from 5.0.3 to 5.0.4.

The system runs with default memory limit (not compiled with
--enable-memory-limit) And changelog says nothing on this possible
change of behaviour.

We do not use the outputbuffering system
We use session_start (as i have seen bugs reported on this earlier)

Reproduce code:
---
readfile(file larger than 2.000.000 bytes)


Expected result:

whole filecontent outputted.
Or some error if hitting some undocumented memorylimit

Actual result:
--
In browser:

no result.
no file downloaded
no messages to user or to server
server stops sending, but client doesn't honor that

Using wget:
a 2.000.000 byte truncated file





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


#32824 [Opn->Bgs]: require_once() don't throw an error msg when file will be included twice

2005-04-25 Thread tony2001
 ID:   32824
 Updated by:   [EMAIL PROTECTED]
 Reported By:  thomas at ecommerce dot com
-Status:   Open
+Status:   Bogus
 Bug Type: Output Control
 Operating System: Linux SuSE 9.2
 PHP Version:  4.3.11
 New Comment:

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

That's exactly how it works.


Previous Comments:


[2005-04-25 14:02:17] thomas at ecommerce dot com

Description:

When an file will be included twice, there wouldn't be thrown
an error message about that. I have set E_ALL in my php.ini.

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


#32833 [Opn->Ver]: Invalid opcode

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

Confirmed with HEAD only.


Previous Comments:


[2005-04-26 12:11:57] jason at amp-design dot net

Description:

Trying to concatenate on to a new/empty array element with the array
push assignment operator, [] =, causes PHP to create a fatal error.

This is tested with the CVS snapshot
http://snaps.php.net/php5-200504260830.tar.gz

Although the code I have given below is technically not correct because
you can not concatenate a string on to an empty/new array element, it
should be seen as an warning and not a fatal error (See notes on
expected result). Also, the error is not very descriptive from a end
user's point of view. I assume the invalid opcode error is obviously a
generic error message that is used by you guys at Zend for debugging.

Previous versions of PHP seem to inconsistent. The reproducable code
doesn't even give me a warning message when tested under PHP5.0.4.
Surely it would be right to make this consistent with concatenating an
undefined variable, by making a "Notice: Undefined variable: test[]"
error.

Reproduce code:
---


Expected result:

Some form of warning stating that you can not concatenate to an
empty/undefined array element. This should be consistent with the fact
that if you did...



that you would get a warning message because $f has not been defined
before. (i.e. Notice: Undefined variable: f)

Actual result:
--
Fatal error: Invalid opcode 30/16/8





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


#32835 [Opn->Bgs]: Undefined variable notice not appearing...

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

Set display_errors to On.


Previous Comments:


[2005-04-26 12:54:23] jason at amp-design dot net

Description:

In the lastest CVS snapshot (8.30 GMT today), the Undefined variable
notice doesn't appear when concatenating to an undefined variable. I
haven't tested this with other scenarios which may also bring up this
error. 

Reproduce code:
---


Expected result:

Notice: Undefined variable: f

Actual result:
--
Nothing





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


#32837 [Opn->Fbk]: error ora 7446 even though everything is correct in pfile

2005-04-26 Thread tony2001
 ID:   32837
 Updated by:   [EMAIL PROTECTED]
 Reported By:  vinodk_u at yahoo dot co dot in
-Status:   Open
+Status:   Feedback
 Bug Type: DBM/DBA related
 Operating System: red hat 8
 PHP Version:  4.3.10
 New Comment:

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

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

Thank you for your interest in PHP.





Previous Comments:


[2005-04-26 14:03:45] vinodk_u at yahoo dot co dot in

Description:

after installation when i want to startup nomount databse 7446 error is
occuring even i checked pfile everything iis correct including files and
permissions this eror is coming perticulerly for udump path and
directory






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


#32839 [Bgs->Fbk]: php 4.3.11 + zlib 1.2.2 + GD library

2005-04-26 Thread tony2001
 ID:   32839
 Updated by:   [EMAIL PROTECTED]
 Reported By:  fev at ukrti dot com dot ua
-Status:   Bogus
+Status:   Feedback
 Bug Type: GD related
 Operating System: Red Hat 7.3 kernel 2.6.3
 PHP Version:  4.3.11
 New Comment:

What exactly looks strange? What are you talking about?


Previous Comments:


[2005-04-26 14:47:56] [EMAIL PROTECTED]

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

Thank you for your interest in PHP.

You use wrong configure parameters.



[2005-04-26 14:45:23] b_ulrich at t-online dot de

You also have to recompile your local mysql version!



[2005-04-26 14:32:12] fev at ukrti dot com dot ua

Description:

My Previous configuration:
Apache 1.3.33
PHP 4.3.10
Zlib 1.2.1
GD 2.0.33 or bundled version
MySQL 4.0.24

I want to update in my system 
PHP 4.3.11
Zlib 1.2.2
And if possible GD 2.0.33 external library.

First i clear my system from old Zlib library (/usr/lib,
/usr/local/lib, /usr/include, /usr/local/include )
and then compile zlib with static and shared libraries in /usr.
Now in my system: ldconfig -v said

libz.so.1 -> libz.so.1.2.2
and /usr/lib has 

-rwxr-xr-x1 root root74672 Apr 25 23:35 libz.a
lrwxr-xr-x1 root root   13 Apr 25 23:35 libz.so ->
libz.so.1.2.2
lrwxr-xr-x1 root root   13 Apr 25 23:35 libz.so.1 ->
libz.so.1.2.2
-rwxr-xr-x1 root root71919 Apr 25 23:35 libz.so.1.2.2

/usr/include has headers source files Zlib 1.2.2.

Then i compile my ordinary configuration like this:

'./configure'
'--prefix=/usr/local/php-4.3.11'
'--with-config-file-path=/usr/local/php-4.3.11'
'--with-mysql=/usr/local/mysql'
'--with-mysql-sock=/usr/local/mysql/mysql.sock'
'--with-zlib=/usr'
'--with-gd' '--with-zlib-dir=/usr'
'--with-jpeg-dir=/usr/local'
'--with-png-dir=/usr/local/libpng-1.2.8'
'--with-freetype-dir=/usr/local/freetype2'
'--with-ttf' '--enable-gd-native-ttf'
'--with-apache=/src/apache/apache_1.3.33'


In console php said
#/usr/local/php-4.3.11/bin/php -i

GD Support => enabled
GD Version => bundled (2.0.28 compatible)
FreeType Support => enabled
FreeType Linkage => with freetype
GIF Read Support => enabled
GIF Create Support => enabled
JPG Support => enabled
PNG Support => enabled
WBMP Support => enabled
XBM Support => enabled

ZLib Support => enabled
Compiled Version => 1.2.2
Linked Version => 1.2.2

BUT phpinfo() in Apache said:

GD Support  enabled
GD Version  bundled (2.0.28 compatible)
FreeType Supportenabled
FreeType Linkagewith freetype
GIF Read Supportenabled
GIF Create Support  enabled
JPG Support enabled
PNG Support enabled
WBMP Supportenabled
XBM Support enabled

ZLib Supportenabled
Compiled Version1.2.2
Linked Version  1.2.1

It's looks very strange.

I have done many compilings and discovered this:
If i exclude GD parameters from configure (don't matter bundled version
or external) i get:

'./configure'
'--prefix=/usr/local/php-4.3.11'
'--with-config-file-path=/usr/local/php-4.3.11'
'--with-mysql=/usr/local/mysql'
'--with-mysql-sock=/usr/local/mysql/mysql.sock'
'--with-zlib=/usr'
'--with-apache=/src/apache/apache_1.3.33'


console php said
#/usr/local/php-4.3.11/bin/php -i

ZLib Support => enabled
Compiled Version => 1.2.2
Linked Version => 1.2.2

AND phpinfo() in Apache said:

ZLib Supportenabled
Compiled Version1.2.2
Linked Version  1.2.2

Can u comment this ???
I don't know how to classify this. Bug? Error Compile? Something
else???
Maybi this is Error of budled GD library with Zlib 1.2.1 library?

And also why GD bundled library from 4.3.10 PHP DON'T SYNCHRONIZE in
4.3.11 PHP with actual GD library 2.0.33???






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


#32839 [Fbk->Bgs]: php 4.3.11 + zlib 1.2.2 + GD library

2005-04-26 Thread tony2001
 ID:   32839
 Updated by:   [EMAIL PROTECTED]
 Reported By:  fev at ukrti dot com dot ua
-Status:   Feedback
+Status:   Bogus
 Bug Type: GD related
 Operating System: Red Hat 7.3 kernel 2.6.3
 PHP Version:  4.3.11
 New Comment:

.


Previous Comments:


[2005-04-26 14:48:41] [EMAIL PROTECTED]

What exactly looks strange? What are you talking about?



[2005-04-26 14:47:56] [EMAIL PROTECTED]

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

Thank you for your interest in PHP.

You use wrong configure parameters.



[2005-04-26 14:45:23] b_ulrich at t-online dot de

You also have to recompile your local mysql version!



[2005-04-26 14:32:12] fev at ukrti dot com dot ua

Description:

My Previous configuration:
Apache 1.3.33
PHP 4.3.10
Zlib 1.2.1
GD 2.0.33 or bundled version
MySQL 4.0.24

I want to update in my system 
PHP 4.3.11
Zlib 1.2.2
And if possible GD 2.0.33 external library.

First i clear my system from old Zlib library (/usr/lib,
/usr/local/lib, /usr/include, /usr/local/include )
and then compile zlib with static and shared libraries in /usr.
Now in my system: ldconfig -v said

libz.so.1 -> libz.so.1.2.2
and /usr/lib has 

-rwxr-xr-x1 root root74672 Apr 25 23:35 libz.a
lrwxr-xr-x1 root root   13 Apr 25 23:35 libz.so ->
libz.so.1.2.2
lrwxr-xr-x1 root root   13 Apr 25 23:35 libz.so.1 ->
libz.so.1.2.2
-rwxr-xr-x1 root root71919 Apr 25 23:35 libz.so.1.2.2

/usr/include has headers source files Zlib 1.2.2.

Then i compile my ordinary configuration like this:

'./configure'
'--prefix=/usr/local/php-4.3.11'
'--with-config-file-path=/usr/local/php-4.3.11'
'--with-mysql=/usr/local/mysql'
'--with-mysql-sock=/usr/local/mysql/mysql.sock'
'--with-zlib=/usr'
'--with-gd' '--with-zlib-dir=/usr'
'--with-jpeg-dir=/usr/local'
'--with-png-dir=/usr/local/libpng-1.2.8'
'--with-freetype-dir=/usr/local/freetype2'
'--with-ttf' '--enable-gd-native-ttf'
'--with-apache=/src/apache/apache_1.3.33'


In console php said
#/usr/local/php-4.3.11/bin/php -i

GD Support => enabled
GD Version => bundled (2.0.28 compatible)
FreeType Support => enabled
FreeType Linkage => with freetype
GIF Read Support => enabled
GIF Create Support => enabled
JPG Support => enabled
PNG Support => enabled
WBMP Support => enabled
XBM Support => enabled

ZLib Support => enabled
Compiled Version => 1.2.2
Linked Version => 1.2.2

BUT phpinfo() in Apache said:

GD Support  enabled
GD Version  bundled (2.0.28 compatible)
FreeType Supportenabled
FreeType Linkagewith freetype
GIF Read Supportenabled
GIF Create Support  enabled
JPG Support enabled
PNG Support enabled
WBMP Supportenabled
XBM Support enabled

ZLib Supportenabled
Compiled Version1.2.2
Linked Version  1.2.1

It's looks very strange.

I have done many compilings and discovered this:
If i exclude GD parameters from configure (don't matter bundled version
or external) i get:

'./configure'
'--prefix=/usr/local/php-4.3.11'
'--with-config-file-path=/usr/local/php-4.3.11'
'--with-mysql=/usr/local/mysql'
'--with-mysql-sock=/usr/local/mysql/mysql.sock'
'--with-zlib=/usr'
'--with-apache=/src/apache/apache_1.3.33'


console php said
#/usr/local/php-4.3.11/bin/php -i

ZLib Support => enabled
Compiled Version => 1.2.2
Linked Version => 1.2.2

AND phpinfo() in Apache said:

ZLib Supportenabled
Compiled Version1.2.2
Linked Version  1.2.2

Can u comment this ???
I don't know how to classify this. Bug? Error Compile? Something
else???
Maybi this is Error of budled GD library with Zlib 1.2.1 library?

And also why GD bundled library from 4.3.10 PHP DON'T SYNCHRONIZE in
4.3.11 PHP with actual GD library 2.0.33???






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


#32835 [Opn->Bgs]: Undefined variable notice not appearing...

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

Most likely you have some .htaccess or entry in httpd.conf that
overrides php.ini's value.
Definitely not a PHP problem.


Previous Comments:


[2005-04-26 15:49:53] jason at amp-design dot net

$p = fgfdghfgf;

where fgfdghfgf is totally undefined gives no warning or error.

I have just double checked with phpinfo() and display errors is on.
However, looking at the php.ini that phpinfo() points to display_errors
is set to the default value of Off. There is nothing overriding the
php.ini value, so it seems like phpinfo is not displaying this value
correctly.

when I turn display errors on, and restart apache, no change happens.
Display errors is still on, and no errors do get displayed.

Should you want to know my command line I am using

 Command './configure' '--enable-bcmath' '--enable-exif'
'--with-gettext' '--enable-calendar' '--prefix=/usr/local'
'--with-apxs2=/usr/local/apache2/bin/apxs' '--with-gd=/usr/local'
'--with-jpeg-dir=/usr/local' '--with-png-dir=usr/local' '--with-xml'
'--with-libxml-dir=/usr/local' '--with-expat-dir=/usr/local/lib'
'--with-dom=/usr/local' '--enable-ftp' '--with-mysql=/usr/local'
'--enable-shared=yes' '--enable-static=yes' '--with-xsl=/usr/local'
'--enable-track-vars' '--enable-sockets' '--enable-wddx'
'--with-xmlrpc' '--with-zlib-dir=/usr/local/include' '--with-iconv'
'--with-curl' '--enable-pcntl' '--with-curlwrappers' '--enable-wddx'
'--with-xmlrpc' '--with-dom' '--with-dom-xslt' '--with-dom-exslt'
'--enable-mbstring' '--enable-mbstr-enc-trans' '--enable-mbregex'
'--with-pear' '--enable-xslt' '--with-xslt-sablot' '--enable-sockets'
'--enable-gd-native-ttf' '--with-ttf' '--enable-debug' '--with-pgsql'
'--enable-shmop' '--with-config-file-path=/etc/php.ini'

the ./configure line. Other than the changing the display errors
setting, and turning log errors to off, the php.ini file remains
untouched from it's default settings.



[2005-04-26 13:08:57] [EMAIL PROTECTED]

Set display_errors to On.



[2005-04-26 12:54:23] jason at amp-design dot net

Description:

In the lastest CVS snapshot (8.30 GMT today), the Undefined variable
notice doesn't appear when concatenating to an undefined variable. I
haven't tested this with other scenarios which may also bring up this
error. 

Reproduce code:
---


Expected result:

Notice: Undefined variable: f

Actual result:
--
Nothing





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


#32823 [Opn->Bgs]: asort orders before uppercase words. a case-insensitive function is needed

2005-04-26 Thread tony2001
 ID:   32823
 Updated by:   [EMAIL PROTECTED]
 Reported By:  asgl at email dot it
-Status:   Open
+Status:   Bogus
-Bug Type: Arrays related
+Bug Type: Feature/Change Request
 Operating System: Windows XP Professional SP2
 PHP Version:  5.0.4
 New Comment:

Then use usort() and implement sort algorithm yourself.


Previous Comments:


[2005-04-26 20:58:58] asgl at email dot it

I've already RTFM. I don't want to use that function because I don't
want to use the "natural order" algorithm.
In fact, I made a script which can work with both MySQL and textfiles
databases. MySQL doesn't support the natural order algorithm in
"SELECT" queries, so if I use that function with the textfile-based
database the result isn't the same.



[2005-04-25 14:29:48] [EMAIL PROTECTED]

Something like natcasesort() perhaps? RTFM..




[2005-04-25 13:59:44] asgl at email dot it

Description:

When I order an array with the asort() function, the words that begin
with an uppercase letter are ordered before the others.
I think a a case-insensitive would be useful. In fact, in the alphabet
there isn't any difference between "A" and "a".
Example:

This returns:

Array
(
[1] => Dog
[2] => Mice
[0] => cat
)

It must return, instead

Array
(
[0] => cat
[1] => Dog
[2] => Mice
)

because "cat" < "Dog" < "Mice".


PS: excuse me for my bad English :)






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


#32852 [Opn->Fbk]: Crash with singleton and __destruct

2005-04-27 Thread tony2001
 ID:   32852
 Updated by:   [EMAIL PROTECTED]
 Reported By:  cox at idecnet dot com
-Status:   Open
+Status:   Feedback
 Bug Type: Reproducible crash
 Operating System: Linux
 PHP Version:  5.0.4
 New Comment:

Please try using this CVS snapshot:

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




Previous Comments:


[2005-04-27 12:44:58] cox at idecnet dot com

Description:

Crash with singleton() and __destruct(), see below.

Tomas V.V.Cox

Reproduce code:
---


Expected result:

i'm called

Actual result:
--
i'm called
i'm called
Segmentation fault (core dumped)






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


#32852 [Opn]: Crash with singleton and __destruct

2005-04-27 Thread tony2001
 ID:   32852
 Updated by:   [EMAIL PROTECTED]
 Reported By:  cox at idecnet dot com
 Status:   Open
 Bug Type: Reproducible crash
 Operating System: Linux
 PHP Version:  5.0.4
 New Comment:

Still works fine here.
Both with HEAD and 5.0.x.


Previous Comments:


[2005-04-27 16:52:39] cox at idecnet dot com

Versions and compile options for the two that crashes for me. In case
it says something for you, if I remove the __destructor() function the
code works good (also you see in the output this function is being
called twice).

5.0.4
~~~

PHP 5.0.4 (cli) (built: Apr 27 2005 11:48:13)
Configure Command =>  './configure' '--prefix=/usr'
'--with-config-file-path=/etc/php5' '--with-xml' '--with-zlib'
'--with-gd' '--enable-gd-native-ttf' '--with-freetype-dir'
'--with-png-dir' '--with-jpeg-dir' '--disable-pear' '--with-mysql=/usr'
'--with-imap=/usr/include/imap' '--with-imap-ssl' '--with-kerberos'
'--with-gettext' '--enable-ftp' '--with-dom' '--with-mhash'
'--with-mcrypt' '--enable-cli' '--enable-sockets' '--enable-sigchild'
'--enable-pcntl' '--enable-shmop' '--enable-posix' '--enable-bcmath'
'--with-xmlrpc' '--with-mime-magic' '--disable-cgi'

5.0.5 Snapshot Stable
~~~

PHP 5.0.5-dev (cli) (built: Apr 27 2005 13:47:32) (DEBUG)
Configure Command =>  './configure' '--prefix=/usr'
'--with-config-file-path=/etc/php5' '--with-xml' '--with-zlib'
'--with-gd' '--enable-gd-native-ttf' '--with-freetype-dir'
'--with-png-dir' '--with-jpeg-dir' '--disable-pear' '--with-mysql=/usr'
'--with-imap=/usr/include/imap' '--with-imap-ssl' '--with-kerberos'
'--with-gettext' '--enable-ftp' '--with-dom' '--with-mhash'
'--with-mcrypt' '--enable-cli' '--enable-sockets' '--enable-sigchild'
'--enable-pcntl' '--enable-shmop' '--enable-posix' '--enable-bcmath'
'--with-xmlrpc' '--with-mime-magic' '--disable-cgi' '--enable-debug'



[2005-04-27 14:41:26] [EMAIL PROTECTED]

For some reason it doesn't crash for me..did you use --enable-debug ?




[2005-04-27 14:10:28] cox at idecnet dot com

I'm not very expert on gdb usage. Please tell me if you need extra
info.

$ gdb /usr/bin/php5.0.5dev core.31085
GNU gdb 6.0-2mdk (Mandrake Linux)
Copyright 2003 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 "i586-mandrake-linux-gnu"...Using host
libthread_db library "/lib/tls/libthread_db.so.1".
 
Core was generated by `/usr/bin/php5.0.5dev test.php'.
Program terminated with signal 11, Segmentation fault.
 
warning: current_sos: Can't read pathname for load map: Input/output
error
 
Reading symbols from /lib/libcrypt.so.1...done.
Loaded symbols for /lib/libcrypt.so.1
Reading symbols from /usr/lib/libexpat.so.0...done.
Loaded symbols for /usr/lib/libexpat.so.0
Reading symbols from /usr/lib/libmysqlclient.so.12...done.
Loaded symbols for /usr/lib/libmysqlclient.so.12
Reading symbols from /lib/libz.so.1...done.
Loaded symbols for /lib/libz.so.1
Reading symbols from /lib/tls/libm.so.6...done.
Loaded symbols for /lib/tls/libm.so.6
Reading symbols from /usr/lib/libmhash.so.2...done.
Loaded symbols for /usr/lib/libmhash.so.2
Reading symbols from /usr/lib/libmcrypt.so.4...done.
Loaded symbols for /usr/lib/libmcrypt.so.4
Reading symbols from /lib/libdl.so.2...done.
Loaded symbols for /lib/libdl.so.2
Reading symbols from /usr/lib/libltdl.so.3...done.
Loaded symbols for /usr/lib/libltdl.so.3
Reading symbols from /lib/libpam.so.0...done.
Loaded symbols for /lib/libpam.so.0
Reading symbols from /usr/lib/libfreetype.so.6...done.
Loaded symbols for /usr/lib/libfreetype.so.6
Reading symbols from /usr/lib/libpng.so.3...done.
Loaded symbols for /usr/lib/libpng.so.3
Reading symbols from /usr/lib/libjpeg.so.62...done.
Loaded symbols for /usr/lib/libjpeg.so.62
Reading symbols from /lib/libresolv.so.2...done.
Loaded symbols for /lib/libresolv.so.2
Reading symbols from /lib/libnsl.so.1...done.
Loaded symbols for /lib/libnsl.so.1
Reading symbols from /usr/lib/libgssapi_krb5.so.2...done.
Loaded symbols for /usr/lib/libgssapi_krb5.so.2
Reading symbols from /usr/lib/libkrb5.so.3...done.
Loaded symbols for /usr/lib/libkrb5.so.3
Reading symbols from /usr/lib/libk5crypto.so.3...done.
Loaded symbols for /usr/lib/libk5crypto.so.3
Reading symbols from /lib/libcom_err.so.2...done.
Loaded symbols for /lib/libcom_err.so.2
Reading symbols from /usr/lib/libssl.so.0.9.7...done.
Loaded symbols for /usr/lib/libssl.so.0.9.7
Reading symbols from /usr/lib/libcrypto.so.0.9.7...done.
L

#32851 [Opn->Bgs]: open_basedir restrictions do not work with file creation in symlinked directory

2005-04-27 Thread tony2001
 ID:   32851
 Updated by:   [EMAIL PROTECTED]
 Reported By:  stegelmann at rz dot rwth-aachen dot de
-Status:   Open
+Status:   Bogus
 Bug Type: Safe Mode/open_basedir
 Operating System: SunOS 5.8
 PHP Version:  4.3.11
 New Comment:

This is expected behaviour and it's documented in the docs:
"When a script tries to open a file with, for example, fopen() or
gzopen(), the location of the file is checked. When the file is outside
the specified directory-tree, PHP will refuse to open it. All symbolic
links are resolved, so it's not possible to avoid this restriction with
a symlink."
http://www.php.net/manual/en/features.safe-mode.php
Pay attentions to the last sentence.


Previous Comments:


[2005-04-27 14:45:30] stegelmann at rz dot rwth-aachen dot de

To perhaps clarify - after the file was created with your code:

$f = fopen("/export2/home/websites/it/test", "w");

the previously unsuccessful attempt:

$f = fopen("/export/home/websites/it/test", "w");

does work (as I mentioned in the initial report).
So just the file's creation fails in combination with the symlink.



[2005-04-27 14:29:51] stegelmann at rz dot rwth-aachen dot de

$f = fopen("/export2/home/websites/it/test", "w");

does work.



[2005-04-27 12:59:39] [EMAIL PROTECTED]

Does this work:

$f = fopen("/export2/home/websites/it/test", "w");

ie. writing to the actual directory..?




[2005-04-27 12:05:45] stegelmann at rz dot rwth-aachen dot de

Description:

We have some Apache/1.3.31 vhosts with open_basedir restrictions:

php_admin_value open_basedir
"/export/home/websites/it/:/export2/home/websites/it/:/tmp/:/var/tmp/"

/export/home/websites/it/ is a symlink to the directory
/export2/home/websites/it/ .

A script writing to an existing file in /export/home/websites/it/ works
without a flaw.
Removing the file (so the script should create the file) produces an
open_basedir warning.

(The creation of a file in the real directory
/export2/home/websites/it/ works.)

I've already checked the (symlink-)ownership and directory-permissions.
safe_mode is disabled for testing purposes.

Reproduce code:
---


Expected result:

As the file's path is in the allowed paths the file should be created
(as it can be read when it exists).

Actual result:
--
Warning: fopen(): open_basedir restriction in effect.
File(/export/home/websites/it/test) is not within the allowed path(s):
(/export/home/websites/it:/export2/home/websites/it:/tmp/:/var/tmp/) in
/export2/home/websites/it/test.php on line 2

Warning: fopen(/export/home/websites/it/test): failed to open stream:
Not owner in /export2/home/websites/it/test.php on line 2





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


#32841 [Opn->Asn]: returned a member variable cannot be turned into reference

2005-04-27 Thread tony2001
 ID:   32841
 Updated by:   [EMAIL PROTECTED]
 Reported By:  wagner at bonn dot edu
-Status:   Open
+Status:   Assigned
 Bug Type: Scripting Engine problem
 Operating System: *
 PHP Version:  4.3.11, 5.0.4
-Assigned To:  
+Assigned To:  andi
 New Comment:

Short version: 
this is expected and the error message clearly says why:
only variables can be referenced and you cannot make a reference to an
expression result.
Long version:
In your case f_default() returns *copy*, not a reference as you wrongly
consider, while f_ref() returns reference and should work indeed.
But I'm a bit surprised to see that f_copy() works, as it should give
the same warning as with f_default().
Concerning the case 2, AFAIK it's because of some reference magic: when
you return $this->v as reference, it turns in refernce itself
(refcount++) and the following call to f_default() returns this
reference.
Though, it would be interesting to see what engine gurus say about it.


Previous Comments:


[2005-04-26 14:54:41] wagner at bonn dot edu

Description:

When returning a member-variable directly as a reference   
parameter into a function, a fatal error occurs:   
Fatal error: Only variables can be passed by reference ...  
The reproduce code displays the bug (for $case=0) as well 
as two simple workarounds that IMHO show that the 
ZEND-Engine should be able to handle this with no need for 
any error. 
This seems to have been around for a while, at least PHP 
4.3.x  
Probably related to 
http://bugs.php.net/bug.php?id=32840 

Reproduce code:
---
$case = 0;

function incr(&$int) {
  return $int++;
}

class foo {
  var $v = 1;
  function &f_ref() { return $this->v; }
  function f_copy() { return (int)$this->v; } //forced copy through
type-cast
  function f_default() { return $this->v; }
}

$foo =& new foo();
switch($case) {
 case 0:
  //default behaviour is broken
  echo incr($foo->f_default())."\n";
 case 1:
   //forced reference works AND makes default behaviour work
afterwards
   echo incr($foo->f_ref())."\n";
   echo incr($foo->f_default())."\n";
   break;
 case 2:
   //forced copy works
   echo incr($foo->f_copy())."\n";
   break;
}

Expected result:

incr() should get a copy of $foo->v 

Actual result:
--
Fatal error: Only variables can be passed by reference in 
foo.php on line 19 
 





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


#32830 [Opn->Fbk]: SQLBindCol on 64bit systems

2005-04-27 Thread tony2001
 ID:   32830
 Updated by:   [EMAIL PROTECTED]
 Reported By:  cvn at interchain dot nl
-Status:   Open
+Status:   Feedback
 Bug Type: ODBC related
 Operating System: Linux
 PHP Version:  4CVS-2005-04-26 (stable)
 New Comment:

Please provide a test case.
Or even a patch, as it seems that you know the extact problem and it's
solution (diff -u would be fine).


Previous Comments:


[2005-04-26 10:49:34] cvn at interchain dot nl

Description:

In the odbc extension SQLBindCol is called with a long int as last
parameter (vallen from the odbc_result struct). This should be an
SDWORD as is also used with SQLBindParameter (and the ODBC API says).

This is no problem on 32bit compiled versions, only on 64bit compiled
PHP versions.

In short: the calls to SQLBindParameter in odbc.c are ok, the calls to
SQLBindCol are not.

Only with negative values like SQL_NULL the problem arises, as the
value is initialised at (long int) 0, but only 'half' (SDWORD) is
written by the driver.

This error is not specific to a PHP version and is there since version
4.

Actual result:
--
When the SQLBindCol would return a negative value like SQL_NULL only
'half' of the long int vallen is written by the  driver, causing php to
think the value is really high, and will dump core when accessing the
output value.





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


#32740 [Opn->Fbk]: signal 11 on make install-pear-installer, xml_parse

2005-04-27 Thread tony2001
 ID:   32740
 Updated by:   [EMAIL PROTECTED]
 Reported By:  dev at stalkerbox dot net
-Status:   Open
+Status:   Feedback
 Bug Type: Reproducible crash
 Operating System: cygwin/xp
 PHP Version:  5.0.4
 New Comment:

Works fine here.
Please try latest snapshot once more.


Previous Comments:


[2005-04-25 23:16:43] dev at stalkerbox dot net

exact same problem persists using php5-STABLE-200504251833:

$ ./configure --enable-maintainer-zts --disable-cgi --with-readline
--with-ssh2
$ make && make install
(...)
Build complete.
(It is safe to ignore warnings about tempnam and tmpnam).

Installing PHP CLI binary:/usr/local/bin/
Installing PHP CLI man page:  /usr/local/man/man1/
Installing PEAR environment:  /usr/local/lib/php/
Signal 11
make[1]: *** [install-pear-installer] Error 139
make: *** [install-pear] Error 2



[2005-04-23 19:19:17] [EMAIL PROTECTED]

Please try using this CVS snapshot:

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





[2005-04-21 22:28:19] dev at stalkerbox dot net

this crash occurs in the stock packages of php in the versions
php5-200504180030, php5-STABLE-200504180037, and php-5.0.4, which were
the latest of each at the time of this bug post.

the steps needed to reproduce:   =P

tar -xvjf php5-*
cd php5-
./configure #i normally use only --enable-maintainer-zts
make && make install



[2005-04-18 08:28:30] [EMAIL PROTECTED]

Thank you for this bug report. To properly diagnose the problem, we
need a short but complete example script to be able to reproduce
this bug ourselves. 

A proper reproducing script starts with ,
is max. 10-20 lines long and does not require any external 
resources such as databases, etc.

If possible, make the script source available online and provide
an URL to it here. Try to avoid embedding huge scripts into the report.



[2005-04-18 05:36:26] dev at stalkerbox dot net

Description:

see #30490, closed

signal 11 on make install-pear-installer, in function
xml_parse.  reproducible on fresh cygwin on other hosts.


i still have this problem in php5-200504180030,
php5-STABLE-200504180037, and php-5.0.4; using cygwin on windows xp
sp2.

this seems to be a php/xml bug.  should this be in pear bugs anyway?

signal 11 at line 802 of /pear/PEAR/Common.php:
if (!xml_parse($xp, $data, 1)) {

does NOT crash (but install doesnt work) if you comment out line 786 of
pear/PEAR/Common.php:
xml_set_element_handler($xp, '_element_start',
'_element_end');
however it doesnt crash within the functions _element_start or
_element_end

Actual result:
--
$ make install-pear-installer
Signal 11
make: *** [install-pear-installer] Error 139





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


#32844 [Opn->Bgs]: libphp4.so not created

2005-04-28 Thread tony2001
 ID:   32844
 Updated by:   [EMAIL PROTECTED]
 Reported By:  adam at adamandliz dot com
-Status:   Open
+Status:   Bogus
 Bug Type: Compile Failure
 Operating System: Fedora Core 2
 PHP Version:  4.3.11
 New Comment:

No bug -> bogus.


Previous Comments:


[2005-04-28 09:04:18] adam at adamandliz dot com

my apologies... I had previously found advice on other pages that uses
libtoolize

Anyway, I deleted the directory and re-created from the tar (4.3.11)

the .so gets created this time.



[2005-04-28 00:15:36] [EMAIL PROTECTED]

You did use fresh sources? And you are not doing something silly like
running buildconf or autoconf or libtoolize..?




[2005-04-27 18:17:29] adam at adamandliz dot com

Still no .so created, only a .a and .la

additionally, the following messages appeared in the make
using piecewise archive linking...
/usr/php-4.3.11/libtool: line 5386: test: : integer expression
expected
/usr/php-4.3.11/libtool: line 5386: test: : integer expression
expected
(last message repeated dozens of times)



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

Try with this configure line:

# ./configure --disable-all --with-apxs2=/usr/local/apache2/bin/apxs 




[2005-04-26 18:29:17] adam at adamandliz dot com

Description:

Firstly, I have no problems under 4.3.9.  However 4.3.10, 4.3.11 and a
recent snapshot fail.

Whenc ompiling php using standard ./configure, make, make install.  the
libphp4.so file is not created.

the configure command is:
./configure --with-apxs2=/usr/local/apache2/bin/apxs
--enable-track-vars --enable-force-cgi-redirect --with-gettext
--with-mysql=/usr/local/mysql 
--with-config-file-path=/usr/local/lib/php -with-imap --enable-mbstring
--with-kerberos --with-imap-ssl

Before the last libtool in the make command, the following is displayed
(this may well be ared herring)

*** Warning: inter-library dependencies are not known to be supported.
*** All declared inter-library dependencies are being dropped.

*** Warning: libtool could not satisfy all declared inter-library
*** dependencies of module libphp4.  Therefore, libtool will create
*** a static module, that should work as long as the dlopening
*** application is linked with the -dlopen flag.

When doing a make install, I get (from the recent snapshot):
[EMAIL PROTECTED] php4-STABLE-200504251836]# make install
Installing PHP SAPI module:   apache2handler
/usr/local/apache2/build/instdso.sh
SH_LIBTOOL='/usr/local/apache2/build/libtool' libphp4.la
/usr/local/apache2/modules
/usr/local/apache2/build/libtool --mode=install cp libphp4.la
/usr/local/apache2/modules/
cp .libs/libphp4.lai /usr/local/apache2/modules/libphp4.la
cp .libs/libphp4.a /usr/local/apache2/modules/libphp4.a
ranlib /usr/local/apache2/modules/libphp4.a
chmod 644 /usr/local/apache2/modules/libphp4.a
libtool: install: warning: remember to run `libtool --finish
/usr/php4-STABLE-200504251836/libs'
Warning!  dlname not found in /usr/local/apache2/modules/libphp4.la.
Assuming installing a .so rather than a libtool archive.
chmod 755 /usr/local/apache2/modules/libphp4.so
chmod: cannot access `/usr/local/apache2/modules/libphp4.so': No such
file or directory
apxs:Error: Command failed with rc=65536
.
make: *** [install-sapi] Error 1






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


#32859 [Opn->Fbk]: Error when attempting to write Clob to oracle

2005-04-28 Thread tony2001
 ID:   32859
 Updated by:   [EMAIL PROTECTED]
 Reported By:  Diomedes_01 at yahoo dot com
-Status:   Open
+Status:   Feedback
 Bug Type: OCI8 related
 Operating System: Solaris 9 (Server)
 PHP Version:  5.0.4
 New Comment:

Thank you for this bug report. To properly diagnose the problem, we
need a short but complete example script to be able to reproduce
this bug ourselves. 

A proper reproducing script starts with ,
is max. 10-20 lines long and does not require any external 
resources such as databases, etc.

If possible, make the script source available online and provide
an URL to it here. Try to avoid embedding huge scripts into the report.

Also, you don't have to modify your script to make it run with PHP5.
Old-style named functions are working in the same way as in PHP4.


Previous Comments:


[2005-04-27 21:44:58] Diomedes_01 at yahoo dot com

Description:

I am receiving errors after upgrading from php 4.3.9 to php 5.0.4 when
attempting to upload a clob to my Oracle database. The code has already
been modified to follow the PHP 5 paradigm; but it is refusing to
function. Code is as follows:

Reproduce code:
---
$sql1 = ("begin append_comments(:incident_id,:comments_id);end;");
   $sth = oci_parse ( $connection, $sql1 ) or display_main_error();
   $clob = oci_new_descriptor ($connection, OCI_D_LOB);
   oci_bind_by_name ( $sth, ":incident_id", $incident );
   oci_bind_by_name ($sth, ":comments_id", &$clob, -1, OCI_B_CLOB );
   $clob->write($comments);
   oci_execute ($sth, OCI_DEFAULT) or display_main_error();
   oci_commit($connection);
   $clob->free();
   oci_free_statement($sth);

Expected result:

The above code should properly insert the clob into the Oracle
database. The code executed correctly in php4.3.9 and the stored
procedure being used functions normally in SQL*Plus. 

Actual result:
--
I receive the following warnings from PHP when attempting to execute
the code:

Warning: OCI-Lob::write() [function.write]: OCILobGetLength:
OCI_INVALID_HANDLE in /www/htdocs/EtrackTest/oracle_update.php on line
218

Warning: oci_execute() [function.oci-execute]: OCIStmtExecute:
ORA-22275: invalid LOB locator specified ORA-06512: at "SYS.DBMS_LOB",
line 366 ORA-06512: at "ETRACK.APPEND_COMMENTS", line 14 ORA-06512: at
line 1 in /www/htdocs/EtrackTest/oracle_update.php on line 219

The code I use is virtually identical to what exists in the PHP
documentation.





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


#32828 [Ver->Csd]: Throwing exception in output_callback function with ob_start and ob_end_clean

2005-04-28 Thread tony2001
 ID:   32828
 Updated by:   [EMAIL PROTECTED]
 Reported By:  rbro at hotmail dot com
-Status:   Verified
+Status:   Closed
 Bug Type: Reproducible crash
 Operating System: *
 PHP Version:  5.0,5.1 CVS (2005-04-26)
 New Comment:

This bug has been fixed in CVS.

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




Previous Comments:


[2005-04-26 00:52:03] rbro at hotmail dot com

Description:

If you throw an exception inside an output_callback function as a
result of using ob_start() and ob_end_clean(), a Segmentation fault
occurs.


Reproduce code:
---



Expected result:

Exception is thrown.


Actual result:
--
Segmentation fault






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


#32850 [Ctl]: PHP crashes on startup because zend_do_implement_interface is called with NULL

2005-04-28 Thread tony2001
 ID:   32850
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
 Status:   Critical
 Bug Type: SQLite related
 Operating System: Debian Sarge Unstable
 PHP Version:  5CVS-2005-04-27 (dev)
 New Comment:

Any info on how to reproduce it?


Previous Comments:


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

Description:

#0  zend_hash_merge_ex (target=0x82f2d38, source=0x98,
pCopyConstructor=0x81d6e10 , size=4,
pMergeSource=0x81c8ec0 , pParam=0x0) at
/home/.../php5-200504251230/Zend/zend_hash.c:818
p = (Bucket *) 0x82f2ca0
t = (void *) 0x82f4908
#1  0x081c8f79 in zend_do_implement_interface (ce=0x82f2ca0,
iface=0x0)
at /home/.../php5-200504251230/Zend/zend_compile.c:2099
No locals.
#2  0x081dbfa9 in zend_class_implements (class_entry=0x82f2ca0,
num_interfaces=2)
at /home/.../php5-200504251230/Zend/zend_API.c:1646
interface_entry = (zend_class_entry *) 0x98
ce_num = 2
impl_num = 2
interface_list = 0xb390 "è#@ ¦/@\214"
#3  0x080f6102 in zm_startup_sqlite (type=1, module_number=4) at
/home/.../php5-200504251230/ext/sqlite/sqlite.c:1024
No locals.
#4  0x081daf38 in zend_register_module_ex (module=0x82f0028) at
/home/.../php5-200504251230/Zend/zend_API.c:1227
lcname = 0x0
module_ptr = (zend_module_entry *) 0x82f0028
#5  0x081a0dc0 in php_startup_extensions (ptr=0x82a450c, count=152) at
/home/.../php5-200504251230/main/main.c:1269
end = (zend_module_entry **) 0x82a453c
#6  0x08246d2b in php_startup_internal_extensions () at
main/internal_functions_cli.c:72
No locals.
#7  0x081a13ea in php_module_startup (sf=0x828396c,
additional_modules=0x0, num_additional_modules=152)
at /home/.../php5-200504251230/main/main.c:1454
zuf = {error_function = 0x819fbb0 ,
printf_function = 0x819f510 ,
  write_function = 0x81a0d70 , fopen_function =
0x81a0220 ,
  message_handler = 0x81a0340 ,
block_interruptions = 0, unblock_interruptions = 0,
get_configuration_directive = 0x81a02f0
,
  ticks_function = 0x81abd60 , on_timeout =
0x81a0480 ,
stream_open_function = 0x81a0270 ,
vspprintf_function = 0x81a42c0 ,
  getenv_function = 0x81a7620 }
  zuv = {import_use_extension = 0x82576e6 ".php",
import_use_extension_length = 136766146, html_errors = 1 '\001'}
#8  0x08245c9e in main (argc=1, argv=0xbbd4) at
/home/.../php5-200504251230/sapi/cli/php_cli.c:632
  exit_status = 0
  c = 152
  file_handle = {type = 0 '\0', filename = 0x82a46f4
"[EMAIL PROTECTED]",
opened_path = 0xbb28 "Hûÿ¿Ûs$\bÜûÿ¿`\234/@", handle = {fd =
134697609, fp = 0x8075289, stream = {handle = 0x8075289,
  reader = 0x402f9c50 , closer = 0xbb34,
interactive = -1073743032}}, free_filename = 219 'Û'}







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


#32850 [Ctl->Fbk]: PHP crashes on startup because zend_do_implement_interface is called with NULL

2005-04-28 Thread tony2001
 ID:   32850
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Critical
+Status:   Feedback
 Bug Type: SQLite related
 Operating System: Debian Sarge Unstable
 PHP Version:  5CVS-2005-04-27 (dev)


Previous Comments:


[2005-04-28 22:00:13] [EMAIL PROTECTED]

Any info on how to reproduce it?



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

Description:

#0  zend_hash_merge_ex (target=0x82f2d38, source=0x98,
pCopyConstructor=0x81d6e10 , size=4,
pMergeSource=0x81c8ec0 , pParam=0x0) at
/home/.../php5-200504251230/Zend/zend_hash.c:818
p = (Bucket *) 0x82f2ca0
t = (void *) 0x82f4908
#1  0x081c8f79 in zend_do_implement_interface (ce=0x82f2ca0,
iface=0x0)
at /home/.../php5-200504251230/Zend/zend_compile.c:2099
No locals.
#2  0x081dbfa9 in zend_class_implements (class_entry=0x82f2ca0,
num_interfaces=2)
at /home/.../php5-200504251230/Zend/zend_API.c:1646
interface_entry = (zend_class_entry *) 0x98
ce_num = 2
impl_num = 2
interface_list = 0xb390 "è#@ ¦/@\214"
#3  0x080f6102 in zm_startup_sqlite (type=1, module_number=4) at
/home/.../php5-200504251230/ext/sqlite/sqlite.c:1024
No locals.
#4  0x081daf38 in zend_register_module_ex (module=0x82f0028) at
/home/.../php5-200504251230/Zend/zend_API.c:1227
lcname = 0x0
module_ptr = (zend_module_entry *) 0x82f0028
#5  0x081a0dc0 in php_startup_extensions (ptr=0x82a450c, count=152) at
/home/.../php5-200504251230/main/main.c:1269
end = (zend_module_entry **) 0x82a453c
#6  0x08246d2b in php_startup_internal_extensions () at
main/internal_functions_cli.c:72
No locals.
#7  0x081a13ea in php_module_startup (sf=0x828396c,
additional_modules=0x0, num_additional_modules=152)
at /home/.../php5-200504251230/main/main.c:1454
zuf = {error_function = 0x819fbb0 ,
printf_function = 0x819f510 ,
  write_function = 0x81a0d70 , fopen_function =
0x81a0220 ,
  message_handler = 0x81a0340 ,
block_interruptions = 0, unblock_interruptions = 0,
get_configuration_directive = 0x81a02f0
,
  ticks_function = 0x81abd60 , on_timeout =
0x81a0480 ,
stream_open_function = 0x81a0270 ,
vspprintf_function = 0x81a42c0 ,
  getenv_function = 0x81a7620 }
  zuv = {import_use_extension = 0x82576e6 ".php",
import_use_extension_length = 136766146, html_errors = 1 '\001'}
#8  0x08245c9e in main (argc=1, argv=0xbbd4) at
/home/.../php5-200504251230/sapi/cli/php_cli.c:632
  exit_status = 0
  c = 152
  file_handle = {type = 0 '\0', filename = 0x82a46f4
"[EMAIL PROTECTED]",
opened_path = 0xbb28 "Hûÿ¿Ûs$\bÜûÿ¿`\234/@", handle = {fd =
134697609, fp = 0x8075289, stream = {handle = 0x8075289,
  reader = 0x402f9c50 , closer = 0xbb34,
interactive = -1073743032}}, free_filename = 219 'Û'}







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


#32751 [Opn->Fbk]: Segfault after code execution (destructor calls,persistent links,shared module)

2005-04-29 Thread tony2001
 ID:   32751
 Updated by:   [EMAIL PROTECTED]
 Reported By:  prism at pld-linux dot org
-Status:   Open
+Status:   Feedback
 Bug Type: Zend Engine 2 problem
 Operating System: PLD Linux Distribution
 PHP Version:  5.0.4


Previous Comments:


[2005-04-28 01:45:43] prism at pld-linux dot org

I can't really test it at the moment. My colleague also 
encountered the same problem after upgrade to glibc 2.3.5 
and PHP 5.0.4 - when he downgraded to PHP 5.0.3 everything 
was working fine. 
I searched the php bugs database for 
"plist_entry_destructor" and I found that one user had 
similar problem in PHP 4.3.x some time ago, and it makes 
me think that this is not only mysql-module related. 
I suggest you to try the new glibc and see if PHP works 
without any problems. If there is anything else I can do, 
just ask. Tomorrow, we will be trying to find the bug in 
the PHP code, so I might have some more information in a 
day or two.



[2005-04-23 19:17:25] [EMAIL PROTECTED]

If you load only and ONLY the mysql extension in your php.ini, can you
reproduce this?




[2005-04-23 01:00:49] prism at pld-linux dot org

Our Configure Command: 
'./configure' 'LDFLAGS=' 'CFLAGS=-O2 -march=i686 -DEAPI=1 
-I/usr/X11R6/include -I/usr/include/apr 
-I/usr/include/apr-util -I/usr/include' 'CXXFLAGS=-O2 
-march=i686' 'FFLAGS=-O2 -march=i686' 'CPPFLAGS=' 
'CC=i686-pld-linux-gcc' 'CXX=i686-pld-linux-g++' 
'--build=i686-pld-linux' '--prefix=/usr' 
'--exec-prefix=/usr' '--bindir=/usr/bin' 
'--sbindir=/usr/sbin' '--sysconfdir=/etc/php' 
'--datadir=/usr/share' '--includedir=/usr/include' 
'--libdir=/usr/lib' '--libexecdir=/usr/lib' 
'--localstatedir=/var' '--sharedstatedir=/var/lib' 
'--mandir=/usr/share/man' '--infodir=/usr/share/info' 
'--x-libraries=/usr/X11R6/lib' 
'--with-apxs2=/usr/sbin/apxs' '--enable-maintainer-zts' 
'--with-config-file-path=/etc/php' 
'--with-exec-dir=/usr/bin' '--disable-debug' 
'--enable-memory-limit' '--enable-bcmath=shared' 
'--enable-calendar=shared' '--enable-ctype=shared' 
'--enable-dba=shared' '--enable-dbx=shared' 
'--enable-dio=shared' '--enable-dom=shared' 
'--enable-exif=shared' '--enable-filepro=shared' 
'--enable-ftp=shared' '--enable-gd-native-ttf' 
'--enable-gd-jus-conf' '--enable-magic-quotes' 
'--enable-mbstring=shared,all' '--enable-mbregex' 
'--enable-pcntl=shared' '--enable-posix=shared' 
'--enable-session' '--enable-shared' 
'--enable-shmop=shared' '--enable-sysvmsg=shared' 
'--enable-sysvsem=shared' '--enable-sysvshm=shared' 
'--enable-track-vars' '--enable-trans-sid' 
'--enable-safe-mode' '--enable-sockets=shared' 
'--enable-ucd-snmp-hack' '--enable-wddx=shared' 
'--enable-xml=shared' '--enable-yp=shared' 
'--enable-soap=shared' '--with-bz2=shared' 
'--with-cpdflib=shared' '--with-curl=shared' '--with-db4' 
'--with-dbase=shared' '--with-expat-dir=shared,/usr' 
'--with-iconv=shared' '--with-fam=shared' 
'--with-filepro=shared' '--with-freetype-dir=shared' 
'--with-gettext=shared' '--with-gd=shared,/usr' 
'--with-gdbm' '--with-gmp=shared' '--with-imap=shared' 
'--with-imap-ssl' '--with-interbase=shared,/usr' 
'--with-jpeg-dir=/usr' '--with-ldap=shared' 
'--with-mcrypt=shared' '--with-mhash=shared' 
'--with-mime-magic=shared,/usr/share/file/magic.mime' 
'--with-ming=shared' '--with-mnogosearch=shared,/usr' 
'--with-msession=shared' '--with-mssql=shared' 
'--with-mysql=shared,/usr' 
'--with-mysql-sock=/var/lib/mysql/mysql.sock' 
'--with-mysqli=shared' '--with-ncurses=shared' 
'--with-openssl=shared' '--with-pcre-regex=shared' 
'--with-pear=/usr/share/pear' '--with-pgsql=shared,/usr' 
'--with-png-dir=/usr' '--with-pspell=shared' 
'--with-readline=shared' '--with-recode=shared' 
'--with-regex=php' '--without-sablot-js' 
'--with-snmp=shared' '--with-sybase=shared,/usr' 
'--with-sybase-ct=shared,/usr' '--with-sqlite=shared,/usr' 
'--with-t1lib=shared' '--with-tidy=shared' 
'--with-tiff-dir=/usr' '--with-unixODBC=shared' 
'--with-xmlrpc=shared,/usr' '--with-xsl=shared' 
'--with-zlib=shared' '--with-zlib-dir=shared,/usr'



[2005-04-22 14:39:36] [EMAIL PROTECTED]

Using this code, from the url you posted:



And I can not reproduce this. Not with PHP 4.3.12-dev, PHP 5.1-dev..and
I have glibc 2.3.4 (FC2)

What is the configure line you are using with PHP?




[2005-04-20 01:17:06] [EMAIL PROTECTED]

Works fine on SuSE 9.2/glibc 2.3.3. 
I'm 100% sure it also works on other systems I have around here, but
I'll check it tomorrow.



The remainder of the comments for this report are too long. To view
the rest of the comments, plea

#30021 [Ver->Fbk]: Infinite loop causing SIGBUS

2005-04-29 Thread tony2001
 ID:   30021
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Verified
+Status:   Feedback
 Bug Type: Zend Engine 2 problem
 Operating System: *
 PHP Version:  5CVS-2005-03-07
 New Comment:

Please try using this CVS snapshot:

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

Can't reproduce with latest HEAD & 5.0, seems to be fixed.


Previous Comments:


[2004-09-08 05:19:49] [EMAIL PROTECTED]

Description:

Calling parent::__construct with call_user_func*() causes what appears
to be an infinite loop. (see backtrace)

Reproduce code:
---
class A {
  function __construct() {}
}
class B extends A {
  function __construct() {
call_user_func(array("parent", "__construct"));
  }
}

$d= new B();

Expected result:

nothing

Actual result:
--
#0  0x285da2a9 in malloc () from /lib/libc.so.5
#1  0x081cc5b5 in _emalloc (size=32,
__zend_filename=0x8283de0
"/usr/home/curt/cvs/php/php-src/Zend/zend_execute_API.c",
__zend_lineno=826,
__zend_orig_filename=0x8285d00
"/usr/home/curt/cvs/php/php-src/Zend/zend_hash.c",
__zend_orig_lineno=169)
at /usr/home/curt/cvs/php/php-src/Zend/zend_alloc.c:181
#2  0x081cca85 in _ecalloc (nmemb=8, size=4,
__zend_filename=0x8283de0
"/usr/home/curt/cvs/php/php-src/Zend/zend_execute_API.c",
__zend_lineno=826,
__zend_orig_filename=0x8285d00
"/usr/home/curt/cvs/php/php-src/Zend/zend_hash.c",
__zend_orig_lineno=169)
at /usr/home/curt/cvs/php/php-src/Zend/zend_alloc.c:319
#3  0x081ed3cf in _zend_hash_init (ht=0x8543224, nSize=0,
pHashFunction=0,
pDestructor=0x81e52ac <_zval_ptr_dtor_wrapper>, persistent=0 '\0',
__zend_filename=0x8283de0
"/usr/home/curt/cvs/php/php-src/Zend/zend_execute_API.c",
__zend_lineno=826)
at /usr/home/curt/cvs/php/php-src/Zend/zend_hash.c:169
#4  0x081daf19 in zend_call_function (fci=0xbfb001f0, fci_cache=0x0)
at /usr/home/curt/cvs/php/php-src/Zend/zend_execute_API.c:826
#5  0x081da044 in call_user_function_ex (function_table=0x82c8000,
object_pp=0x0, function_name=0x8542624, retval_ptr_ptr=0xbfb00268,
param_count=0, params=0x85426a8, no_separation=0,
symbol_table=0x0)
at /usr/home/curt/cvs/php/php-src/Zend/zend_execute_API.c:556
#6  0x08126406 in zif_call_user_func (ht=1, return_value=0x8542664,
this_ptr=0x0, return_value_used=0)
at
/usr/home/curt/cvs/php/php-src/ext/standard/basic_functions.c:2010
#7  0x0820fb4b in zend_do_fcall_common_helper
(execute_data=0xbfb00350)
at /usr/home/curt/cvs/php/php-src/Zend/zend_execute.c:2983
#8  0x082102c7 in zend_do_fcall_handler (execute_data=0xbfb00350)
at /usr/home/curt/cvs/php/php-src/Zend/zend_execute.c:3117
#9  0x0820bec6 in execute (op_array=0x835a424)
at /usr/home/curt/cvs/php/php-src/Zend/zend_execute.c:1498
#10 0x081daf7b in zend_call_function (fci=0xbfb004a0, fci_cache=0x0)
at /usr/home/curt/cvs/php/php-src/Zend/zend_execute_API.c:834
#11 0x081da044 in call_user_function_ex (function_table=0x82c8000,
object_pp=0x0, function_name=0x8542424, retval_ptr_ptr=0xbfb00518,
param_count=0, params=0x85424a8, no_separation=0,
symbol_table=0x0)
at /usr/home/curt/cvs/php/php-src/Zend/zend_execute_API.c:556
#12 0x08126406 in zif_call_user_func (ht=1, return_value=0x8542464,
this_ptr=0x0, return_value_used=0)
at
/usr/home/curt/cvs/php/php-src/ext/standard/basic_functions.c:2010
#13 0x0820fb4b in zend_do_fcall_common_helper
(execute_data=0xbfb00600)
at /usr/home/curt/cvs/php/php-src/Zend/zend_execute.c:2983
#14 0x082102c7 in zend_do_fcall_handler (execute_data=0xbfb00600)
at /usr/home/curt/cvs/php/php-src/Zend/zend_execute.c:3117
#15 0x0820bec6 in execute (op_array=0x835a424)
at /usr/home/curt/cvs/php/php-src/Zend/zend_execute.c:1498


#9028 0x081daf7b in zend_call_function (fci=0xbfbfcbf0, fci_cache=0x0)
at /usr/home/curt/cvs/php/php-src/Zend/zend_execute_API.c:834
#9029 0x081da044 in call_user_function_ex (function_table=0x82c8000,
object_pp=0x0, function_name=0x8359624, retval_ptr_ptr=0xbfbfcc68,
param_count=0, params=0x83596a8, no_separation=0,
symbol_table=0x0)
at /usr/home/curt/cvs/php/php-src/Zend/zend_execute_API.c:556
#9030 0x08126406 in zif_call_user_func (ht=1, return_value=0x8359664,
this_ptr=0x0, return_value_used=0)
at
/usr/home/curt/cvs/php/php-src/ext/standard/basic_functions.c:2010
#9031 0x0820fb4b in zend_do_fcall_common_helper
(execute_data=0xbfbfcd50)
at /usr/home/curt/cvs/php/php-src/Zend/zend_execute.c:2983
#9032 0x082102c7 in zend_do_fcall_handler (execute_data=0xbfbfcd50)
at /usr/home/curt/cvs/php/php-src/Zend/zend_execute.c:3117
#9033 0x0820bec6 in execute (op_array=0x835a424)
at /usr/home/curt/cvs/php/php-src/Zend/zend_execute.c:1498
#9034 0x0820fce4 in zend_do_fcall_common_helper
(execute_data=0xb

#29681 [Ver->Fbk]: Parent: child process exited with status 3221225477

2005-04-29 Thread tony2001
 ID:   29681
 Updated by:   [EMAIL PROTECTED]
 Reported By:  tony at marston-home dot demon dot co dot uk
-Status:   Verified
+Status:   Feedback
 Bug Type: Zend Engine 2 problem
 Operating System: *
 PHP Version:  5CVS-STABLE-2005-01-18
 New Comment:

Please try using this CVS snapshot:

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




Previous Comments:


[2005-03-31 09:21:16] mail at kasimir-k dot fi

In addition to my yesterday's comment: I installed PHP 4.3.10 on the
WinXP - no effect on the problem.

And pardon me if I'm too vague, but I'd like to mention that I remember
having this problem a couple times before: once the data got large
enough, my WinXP testing server stopped working, but Linux production
server worked fine - hth.

Also, it seems that this might be an Apache bug:
http://issues.apache.org/bugzilla/show_bug.cgi?id=12340



[2005-03-30 12:06:49] mail at kasimir-k dot fi

I have this loop:

for ($i = 0, $_i = count($items); $i < $_i; $i++) {
   $item_index[$items[$i]['item_id']] =& $items[$i];
}

I run it on two platforms:
WinXP - PHP 4.3.4 - Apache/2.0.48 (Win32)
Linux - PHP 4.3.10 - Apache/2.0.52 (Fedora)

On Linux - no problems.
On WinXP - once count($item_classes) > 107, the script dies



[2005-01-18 14:55:44] [EMAIL PROTECTED]

The original problem here, reproduced using the script bundle posted by
Tony, triggers crashes in free() when run with "MALLOC_CHECK_=3", using
5.0.4-dev.  Backtrace below.  Doesn't look like this is
Apache-related:

#5  0x0041baca in free () from /lib/tls/libc.so.6
No symbol table info available.
#6  0x010035b7 in _efree (ptr=0x86e443c) at
/net/jedi/local/php/5.0/Zend/zend_alloc.c:287
p = (zend_mem_header *) 0x4e0800
cache_index = 6
#7  0x0101f1fa in zend_hash_destroy (ht=0x86f1714)
at /net/jedi/local/php/5.0/Zend/zend_hash.c:526
p = (Bucket *) 0x0
q = (Bucket *) 0x86e47dc
#8  0x01029c7f in zend_objects_free_object_storage (object=0x872be84)
at /net/jedi/local/php/5.0/Zend/zend_objects.c:91
No locals.
#9  0x0102c24a in zend_objects_store_del_ref (zobject=0x0)
at /net/jedi/local/php/5.0/Zend/zend_objects_API.c:159
handle = 1
obj = (struct _store_object *) 0x86d9b88
#10 0x010170d0 in _zval_dtor (zvalue=0x86efb2c)
at /net/jedi/local/php/5.0/Zend/zend_variables.c:61
No locals.
#11 0x0100c491 in _zval_ptr_dtor (zval_ptr=0x10a995c)
at /net/jedi/local/php/5.0/Zend/zend_execute_API.c:392
No locals.
#12 0x0104b894 in zend_do_fcall_common_helper
(execute_data=0xbff34610,
opline=0x86ee780, op_array=0x86e306c)
at /net/jedi/local/php/5.0/Zend/zend_execute.c:2797
i = 141458196
p = (zval **) 0x86efb2c
arg_count = 17471360
original_return_value = (zval **) 0xbff346ac
current_scope = (zend_class_entry *) 0x0
current_this = (zval *) 0x0
return_value_used = 1
should_change_scope = 1 '\001'
#13 0x0104ba48 in zend_do_fcall_by_name_handler (execute_data=0x0,
opline=0x86ee780,
op_array=0x86e306c) at
/net/jedi/local/php/5.0/Zend/zend_execute.c:2825
No locals.
#14 0x01039b77 in execute (op_array=0x86e306c)
at /net/jedi/local/php/5.0/Zend/zend_execute.c:1400
execute_data = {opline = 0x86ee780, function_state = {
function_symbol_table = 0x870e404, function = 0x872a444, reserved =
{0x100f260,
  0x86e3364, 0xbff36970, 0x0}}, fbc = 0x872a444, fbc_constructor =
0x0,
  op_array = 0x86e306c, object = 0x86efb2c, Ts = 0xbff33430,
  original_in_execution = 0 '\0', calling_scope = 0x86f0a54,
prev_execute_data = 0x0}
#15 0x01018b25 in zend_execute_scripts (type=8, retval=0x0,
file_count=3)
at /net/jedi/local/php/5.0/Zend/zend.c:1069
files = 0xbff34764 ""
i = 1
file_handle = (zend_file_handle *) 0xbff36970
orig_op_array = (zend_op_array *) 0x0
local_retval = (zval *) 0x0




[2004-11-16 12:23:16] php_bug at cklowe dot com

This bug looks to be the same as bug 26286:
http://bugs.php.net/bug.php?id=26286



[2004-10-21 19:20:21] tony at marston-home dot demon dot co dot uk

I have reinstated my sample code at
http://www.tonymarston.co.uk/error.zip

There are instructions inside on how to reproduce the error.



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

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


#32799 [Opn->Ver]: crash: calling the corresponding global var during the destruct

2005-04-29 Thread tony2001
 ID:   32799
 Updated by:   [EMAIL PROTECTED]
 Reported By:  rd dot contact at free dot fr
-Status:   Open
+Status:   Verified
-Bug Type: Reproducible crash
+Bug Type: Zend Engine 2 problem
 Operating System: *
 PHP Version:  5CVS-2005-04-25


Previous Comments:


[2005-04-22 19:34:46] rd dot contact at free dot fr

/*
-- TEST 1
   I use the global var instead of "$this" to demonstrate 
   that calling it will segfault php.
   Try TEST2 to see why it could be useful to use the global
   var during the destruct.
   unset($p) instead of $p=[anything], don't crash.
*/
class test{
  public $c=1;
  function __destruct (){
$GLOBALS['p']->c++; // no warning
print $GLOBALS['p']->c; // segfault
  }
}
$p=new test;
$p=null; //destroy the object by a new assignment (segfault)

//---CUT

/*
   -- TEST 2
   More realistic example:
   During the destruct, I need to call an external function 
   that uses the global var of the object.
   calling a methode: works
   incrementing a property: segfault
*/

function dbug($msg){
$GLOBALS['p']->printmsg($msg); // works
$GLOBALS['p']->c++; // segfault
}

class test{
  public $c=1;
  function __destruct (){dbug('Destruct');}
  function printmsg($msg){print $msg;}
}
$p=new test;
$p=null; //destroy the object by a new assignment (segfault)



[2005-04-22 14:31:18] [EMAIL PROTECTED]

Can you give a bit more realistic example script?
The one here does not make any sense..




[2005-04-22 05:19:51] rd dot contact at free dot fr

Description:

During the __destruct, when using the global var assigned to the
object, php crashes in some cases.





Reproduce code:
---
class test{
  function __destruct (){
//$GLOBALS['p']=$this; // <- this crash apache for all tests
//$GLOBALS['p']++; // <- this crash apache for all tests
print_r($GLOBALS['p']); // <- crash only test 1. test 2 =>
"Undefined variable p"
  }
}
$p=new test;

//test 1
$p=1; // crash apache (as $p=null, $p='bug', $p=new test ...)

//but,

//test 2
//unset($p); //  no crash: "Undefined variable:  p on line 5"

Expected result:

No crash, and a way to use the global var during destruct.
(so destruct could call external functions that use the global var of
the object. Why not unregister the global var after the destruct call
?)







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


#32395 [Opn->Asn]: odbc_execute modifies the param array

2005-04-29 Thread tony2001
 ID:   32395
 Updated by:   [EMAIL PROTECTED]
 Reported By:  treehousetim at gmail dot com
-Status:   Open
+Status:   Assigned
 Bug Type: ODBC related
 Operating System: *
 PHP Version:  4CVS, 5CVS (2005-03-24)
-Assigned To:  
+Assigned To:  kalowsky
 New Comment:

As far as I understand, it has to change the input array, because it
should convert all the values in strings without separating them to be
able to get returned values from stored proc.
Assigning it to the maintainer, though.


Previous Comments:


[2005-03-21 23:04:36] treehousetim at gmail dot com

More specifically, all entries in the array are changed to string
types.
here is more data as requested using var_dump instead of print_r.

BEFORE:

array(3) {
  [0]=>
  int(44)
  [1]=>
  NULL
  [2]=>
  NULL
}

AFTER:
array(3) {
  [0]=>
  string(2) "44"
  [1]=>
  string(0) ""
  [2]=>
  string(0) ""
}



[2005-03-21 22:45:37] [EMAIL PROTECTED]

Please change print_r -> var_dump to get more detailed information out
of the $paramList variable.



[2005-03-21 18:38:28] treehousetim at gmail dot com

Description:

Calling odbc_execute modifies the input paramList array.
This happens even when I try to make a copy of the array before passing
it to odbc_execute.

Specifically, null parameters are changed to zero length strings.


Reproduce code:
---


Expected result:

NULL
string
Array
(
[0] => 44
[1] => 
[2] => 
)

Actual result:
--
NULL
NULL
Array
(
[0] => 44
[1] => 
[2] => 
)





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


#32422 [Asn->Fbk]: Access Violation on calling PEAR Date::before

2005-04-29 Thread tony2001
 ID:   32422
 Updated by:   [EMAIL PROTECTED]
 Reported By:  rob at wildlime dot com
-Status:   Assigned
+Status:   Feedback
 Bug Type: Reproducible crash
 Operating System: Windows XP SP2
 PHP Version:  4.3.10
 Assigned To:  pierre
 New Comment:

Please try using this CVS snapshot:

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

Is it still reproducible ?
If yes, is it reproducible on NON-win32 systems ?


Previous Comments:


[2005-04-08 01:23:40] rob at wildlime dot com

Any chance of PHP catching the exception in putenv/gettenv and chucking
a more informative error?  Would help anyone else who hits this problem.



[2005-04-08 00:27:12] [EMAIL PROTECTED]

Pierre promised to look into this..(or rather bogus this with good
explanation..)




[2005-04-06 05:52:25] rob at wildlime dot com

Looks like this bug has been encountered before:
http://pear.php.net/bugs/bug.php?id=2344

.. but the Date package owners maintain that it's not their problem.

(Dunno how I didn't find that earlier :-/  I did search the bug DBs
before posting, honest!)



[2005-04-06 04:23:22] rob at wildlime dot com

btw, the extensions loaded before were the ones packaged with PHP5, not
old 4.3.10 ones!



[2005-04-06 04:21:17] rob at wildlime dot com

sorry for the delay...

using PHP/5.1.0-dev
 - no extensions loaded
 - PEAR installed (default packages and Date)

Got the same access violation.

stack trace:
ntdll!RtlpCoalesceFreeBlocks+0x21
ntdll!RtlFreeHeap+0x2e9
msvcrt!free+0xc3
msvcrt!__crtsetenv+0x193
msvcrt!_putenv_lk+0x42
msvcrt!_putenv+0x20
WARNING: Stack unwind information not available. Following frames may
be wrong.
php5ts!php_get_inf+0x1083



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

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


#31300 [Ver->Fbk]: ArrayAccess and __get crash when using string concat in key

2005-04-29 Thread tony2001
 ID:   31300
 Updated by:   [EMAIL PROTECTED]
 Reported By:  gardan at gmx dot com
-Status:   Verified
+Status:   Feedback
 Bug Type: Zend Engine 2 problem
 Operating System: *
 PHP Version:  5CVS-2005-01-10
 New Comment:

Please try using this CVS snapshot:

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

Can't reproduce with latest HEAD & 5.0.


Previous Comments:


[2005-03-05 03:55:23] matt dot bevan at marginsoftware dot com

Consider this bug confirmed using Apache/2.0.52   
(Gentoo/Linux) PHP/5.0.3 but is not re-producible in a 
small amount of code. 
 
In my case, performing strange acts got around the bug 
when using the array access more than once with three 
other variable assignments in-between the first call and 
second: 
 - The first dot-concatenated call worked fine. 
 - The second segfaulted Apache, unless: 
- The first call is commented out, or 
- The second call is placed right below the first, or 
- One line of three lines is commented out. 
- All array accesses are changed to use sprintf 
  not dot concatenation. 
 
It doesn't matter which line of the three simple, static 
variable assignments is commented.

This bug drove me crazy all today.  I'm going to have  
nightmares about this bug.  ;)



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

ArrayAccess is defined and controlled by the engine not SPL



[2004-12-26 22:40:38] gardan at gmx dot com

Still crashing with cvs snapshot (Windows).



[2004-12-26 12:24:08] [EMAIL PROTECTED]

Please try using this CVS snapshot:

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



[2004-12-26 07:32:35] Beater at orgalan dot de

I can partially confirm this for 5.0.3 running on Windows XP. The
behaviour is very unpredictable.

Following you'll find some test cases and the behaviour on my system.

class arr implements ArrayAccess {
public $x = array("ab_cd" => "hello");
function offsetExists($offset) { return isset($this->x[$offset]); }
function offsetSet($offset, $value) { $this->x[$offset] = $value; }
function offsetGet($offset) { return $this->x[$offset]; }
function offsetUnset($offset) { unset($this->x[$offset]); }
function __get($offset) { return $this->x[$offset]; }
}
$test = new arr;

case 1:

echo($test["ab"."_cd"]);// crashs

case 2:

echo($test["ab_cd"]);   // works
echo($test["ab"."_cd"]);// works

case 3:
echo($test["ab_cd"]);   // works
echo($test->{"ab_cd"}); // works
echo($test["ab"."_cd"]);// crashs

sounds stupid, but you'll confirm it, i guess



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

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


#29707 [Asn]: When execute the global requisition bellow the thread crashes

2005-04-29 Thread tony2001
 ID:   29707
 Updated by:   [EMAIL PROTECTED]
 Reported By:  edernucci at hotmail dot com
 Status:   Assigned
 Bug Type: Scripting Engine problem
 Operating System: Windows XP Professional SP1
 PHP Version:  4.* and 5.*
 Assigned To:  andi
 New Comment:

Still valid with 5.0.x and 4.3.x, but HEAD works fine.


Previous Comments:


[2004-09-22 00:21:11] [EMAIL PROTECTED]

Please check latest version of PHP 5 CVS (Latest CVS (5.1.x-dev) at
snaps.php.net).
Not sure about PHP 4.3.x and PHP 5.0.x yet because we might want to run
this patch for a while before we merge into them.



[2004-08-17 08:01:58] [EMAIL PROTECTED]

Confirmed with both PHP 4 and PHP 5:

valgrind:
==12558== Invalid read of size 4
==12558==at 0x8305A91: zend_pzval_unlock_func (zend_execute.c:65)
==12558==by 0x8305B94: _get_zval_ptr (zend_execute.c:100)
==12558==by 0x82FBF85: zend_fetch_var_address (zend_execute.c:737)
==12558==by 0x82FECBF: zend_fetch_w_handler (zend_execute.c:2004)
==12558==  Address 0x9 is not stack'd, malloc'd or (recently) free'd
==12558==
==12558== Process terminating with default action of signal 11
(SIGSEGV)
==12558==  Access not within mapped region at address 0x9
==12558==at 0x8305A91: zend_pzval_unlock_func (zend_execute.c:65)
==12558==by 0x8305B94: _get_zval_ptr (zend_execute.c:100)
==12558==by 0x82FBF85: zend_fetch_var_address (zend_execute.c:737)
==12558==by 0x82FECBF: zend_fetch_w_handler (zend_execute.c:2004)
==12558==

gdb trace:
Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 16384 (LWP 12626)]
0x08305a91 in zend_pzval_unlock_func (z=0x1)
at /dat/dev/php/php-5.0dev/Zend/zend_execute.c:65
65  z->refcount--;
(gdb) bt
#0  0x08305a91 in zend_pzval_unlock_func (z=0x1)
at /dat/dev/php/php-5.0dev/Zend/zend_execute.c:65
#1  0x08305b95 in _get_zval_ptr (node=0x85bec78, Ts=0x85bd704,
should_free=0xbfffd31c) at
/dat/dev/php/php-5.0dev/Zend/zend_execute.c:100
#2  0x082fbf86 in zend_fetch_var_address (opline=0x85bec60,
Ts=0x85bd704,
type=1) at /dat/dev/php/php-5.0dev/Zend/zend_execute.c:737
#3  0x082fecc0 in zend_fetch_w_handler (execute_data=0xbfffd380,
opline=0x85bec60, op_array=0x85bede8)
at /dat/dev/php/php-5.0dev/Zend/zend_execute.c:2004
#4  0x082fd8f1 in execute (op_array=0x85bede8)
at /dat/dev/php/php-5.0dev/Zend/zend_execute.c:1391
#5  0x408c7318 in xdebug_execute (op_array=0x85bede8)
at /dat/dev/php/xdebug/xdebug.c:1041
#6  0x08301078 in zend_do_fcall_common_helper
(execute_data=0xbfffd4d0,
opline=0x85bd254, op_array=0x85b8de4)
at /dat/dev/php/php-5.0dev/Zend/zend_execute.c:2728
#7  0x083015fb in zend_do_fcall_handler (execute_data=0xbfffd4d0,
opline=0x85bd254, op_array=0x85b8de4)
at /dat/dev/php/php-5.0dev/Zend/zend_execute.c:2828
#8  0x082fd8f1 in execute (op_array=0x85b8de4)
at /dat/dev/php/php-5.0dev/Zend/zend_execute.c:1391
#9  0x408c7318 in xdebug_execute (op_array=0x85b8de4)
at /dat/dev/php/xdebug/xdebug.c:1041

(And yes, it also segfaults without Xdebug at the same place)

Derick



[2004-08-16 18:06:15] edernucci at hotmail dot com

Description:

I know this is a erroneous code, but the thread hangs on the server
(Apache 1.3.29 / Windows XP Professional SP1).
I don't know how to solve this.

Reproduce code:
---


Expected result:

Just trying to hang the webserver.
Any user can do this in my shared enviroment.






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


#32897 [Opn->Fbk]: session_start(): Failed to initialize storage module: user

2005-04-30 Thread tony2001
 ID:   32897
 Updated by:   [EMAIL PROTECTED]
 Reported By:  dmih at in-solve dot ru
-Status:   Open
+Status:   Feedback
 Bug Type: Session related
 Operating System: Win32/all
 PHP Version:  4.3.10
 New Comment:

1) Upgrade to the latest version first. 4.3.10 is NOT the latest
version available.
2) Instead of complaining and telling how many customers you have
please tell how to reproduce it because none of us is able to reproduce
it till now.



Previous Comments:


[2005-04-30 11:45:47] dmih at in-solve dot ru

Please set it to bogus once again to indicate that I am really wrong,
that will clearly tell me that I should just wait without additional
comments/reports.
(that will be disapointing)

I just want to note that previous bug is reproducable, this - not
(random bug). These bugs may be related, but not the same surely.



[2005-04-30 11:39:32] dmih at in-solve dot ru

Please kindly comment this:

-
[EMAIL PROTECTED]  sais:

I don't see how this relates to my problem besides the error message.
I
ask you guys kindly to open a new report about your specific problem.
Your problem has no relation to session handler loosing when calling
session_destroy.
-

That is, [EMAIL PROTECTED] will say it again - "you do not call
session_destroy".
So this should be separate bug, I guess.

Please understand me; I am reporting and commenting this bug for 3
months already. Our customers of 3 most loaded servers feel stupid
because of this bug.
I do not want this bug to be ignored just because you think that it is
related to call to session_destroy or whatever - there is no need for
this call for this bug to happen.
_Another_ report is bogus, I believe.



[2005-04-30 11:34:22] dmih at in-solve dot ru

I see that I should not post this bug again, please forgive me. 
I just wanted to mark somehow that it is much simplier to reproduce. I
am also developer and I am used to post another bug if bug reproduction
alters a lot.



[2005-04-30 11:28:55] dmih at in-solve dot ru

It seems that this code fails to get proper handler setting.

/* Open session handler first */
if (PS(mod)->s_open(&PS(mod_data), PS(save_path), PS(session_name)
TSRMLS_CC) == FAILURE) {
php_error_docref(NULL TSRMLS_CC, E_ERROR, "Failed to initialize
storage module: %s (path: %s)", PS(mod)->s_name, PS(save_path));
return;
}



[2005-04-30 11:28:07] [EMAIL PROTECTED]

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

Thank you for your interest in PHP.

As you said, this is same as bug #32330 (why did you have to report
this again?)





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

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


#32897 [Opn->Fbk]: session_start(): Failed to initialize storage module: user

2005-04-30 Thread tony2001
 ID:   32897
 Updated by:   [EMAIL PROTECTED]
 Reported By:  dmih at in-solve dot ru
-Status:   Open
+Status:   Feedback
 Bug Type: Session related
 Operating System: Win32/all
 PHP Version:  4.3.10
 New Comment:

>how can I tell reproduce code if it happens after hours of
>heavy load, with low probability?

Maybe it means that you need to switch from a system that needs to be
rebooted every day to a system where you can at least find sources of
your problem?

Anyway, as I've already said, we're unable to reproduce it at all. So,
if you can do it - please help us to understand what's wrong.

Marking the report as waiting for feedback.
Please open it when you have more info.


Previous Comments:


[2005-04-30 12:06:53] dmih at in-solve dot ru

I just want to solve this issue, please understand.

I'll upgrate one server to 4.11 now. I'll tell if this happens there.

bug http://bugs.php.net/bug.php?id=25876 was seen by people quite
often. 
Please anyway tell me how can I tell reproduce code if it happens after
hours of heavy load, with low probability?
Is there any strategy for this?

Please tell me, if I do not find how to reproduce it, you will not pay
attention to this?

Thank you.



[2005-04-30 11:57:33] [EMAIL PROTECTED]

1) Upgrade to the latest version first. 4.3.10 is NOT the latest
version available.
2) Instead of complaining and telling how many customers you have
please tell how to reproduce it because none of us is able to reproduce
it till now.




[2005-04-30 11:45:47] dmih at in-solve dot ru

Please set it to bogus once again to indicate that I am really wrong,
that will clearly tell me that I should just wait without additional
comments/reports.
(that will be disapointing)

I just want to note that previous bug is reproducable, this - not
(random bug). These bugs may be related, but not the same surely.



[2005-04-30 11:39:32] dmih at in-solve dot ru

Please kindly comment this:

-
[EMAIL PROTECTED]  sais:

I don't see how this relates to my problem besides the error message.
I
ask you guys kindly to open a new report about your specific problem.
Your problem has no relation to session handler loosing when calling
session_destroy.
-

That is, [EMAIL PROTECTED] will say it again - "you do not call
session_destroy".
So this should be separate bug, I guess.

Please understand me; I am reporting and commenting this bug for 3
months already. Our customers of 3 most loaded servers feel stupid
because of this bug.
I do not want this bug to be ignored just because you think that it is
related to call to session_destroy or whatever - there is no need for
this call for this bug to happen.
_Another_ report is bogus, I believe.



[2005-04-30 11:34:22] dmih at in-solve dot ru

I see that I should not post this bug again, please forgive me. 
I just wanted to mark somehow that it is much simplier to reproduce. I
am also developer and I am used to post another bug if bug reproduction
alters a lot.



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

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


#29681 [Opn->Csd]: Parent: child process exited with status 3221225477

2005-04-30 Thread tony2001
 ID:   29681
 Updated by:   [EMAIL PROTECTED]
 Reported By:  tony at marston-home dot demon dot co dot uk
-Status:   Open
+Status:   Closed
 Bug Type: Zend Engine 2 problem
 Operating System: *
 PHP Version:  5CVS-STABLE-2005-01-18
 New Comment:

Good. Not reproducible -> closed.


Previous Comments:


[2005-04-30 14:09:53] tony at marston-home dot demon dot co dot uk

I have tried that snapshot and the problem has not re-appeared. It
appears you have fixed it.



[2005-04-29 11:57:09] [EMAIL PROTECTED]

Please try using this CVS snapshot:

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





[2005-03-31 09:21:16] mail at kasimir-k dot fi

In addition to my yesterday's comment: I installed PHP 4.3.10 on the
WinXP - no effect on the problem.

And pardon me if I'm too vague, but I'd like to mention that I remember
having this problem a couple times before: once the data got large
enough, my WinXP testing server stopped working, but Linux production
server worked fine - hth.

Also, it seems that this might be an Apache bug:
http://issues.apache.org/bugzilla/show_bug.cgi?id=12340



[2005-03-30 12:06:49] mail at kasimir-k dot fi

I have this loop:

for ($i = 0, $_i = count($items); $i < $_i; $i++) {
   $item_index[$items[$i]['item_id']] =& $items[$i];
}

I run it on two platforms:
WinXP - PHP 4.3.4 - Apache/2.0.48 (Win32)
Linux - PHP 4.3.10 - Apache/2.0.52 (Fedora)

On Linux - no problems.
On WinXP - once count($item_classes) > 107, the script dies



[2005-01-18 14:55:44] [EMAIL PROTECTED]

The original problem here, reproduced using the script bundle posted by
Tony, triggers crashes in free() when run with "MALLOC_CHECK_=3", using
5.0.4-dev.  Backtrace below.  Doesn't look like this is
Apache-related:

#5  0x0041baca in free () from /lib/tls/libc.so.6
No symbol table info available.
#6  0x010035b7 in _efree (ptr=0x86e443c) at
/net/jedi/local/php/5.0/Zend/zend_alloc.c:287
p = (zend_mem_header *) 0x4e0800
cache_index = 6
#7  0x0101f1fa in zend_hash_destroy (ht=0x86f1714)
at /net/jedi/local/php/5.0/Zend/zend_hash.c:526
p = (Bucket *) 0x0
q = (Bucket *) 0x86e47dc
#8  0x01029c7f in zend_objects_free_object_storage (object=0x872be84)
at /net/jedi/local/php/5.0/Zend/zend_objects.c:91
No locals.
#9  0x0102c24a in zend_objects_store_del_ref (zobject=0x0)
at /net/jedi/local/php/5.0/Zend/zend_objects_API.c:159
handle = 1
obj = (struct _store_object *) 0x86d9b88
#10 0x010170d0 in _zval_dtor (zvalue=0x86efb2c)
at /net/jedi/local/php/5.0/Zend/zend_variables.c:61
No locals.
#11 0x0100c491 in _zval_ptr_dtor (zval_ptr=0x10a995c)
at /net/jedi/local/php/5.0/Zend/zend_execute_API.c:392
No locals.
#12 0x0104b894 in zend_do_fcall_common_helper
(execute_data=0xbff34610,
opline=0x86ee780, op_array=0x86e306c)
at /net/jedi/local/php/5.0/Zend/zend_execute.c:2797
i = 141458196
p = (zval **) 0x86efb2c
arg_count = 17471360
original_return_value = (zval **) 0xbff346ac
current_scope = (zend_class_entry *) 0x0
current_this = (zval *) 0x0
return_value_used = 1
should_change_scope = 1 '\001'
#13 0x0104ba48 in zend_do_fcall_by_name_handler (execute_data=0x0,
opline=0x86ee780,
op_array=0x86e306c) at
/net/jedi/local/php/5.0/Zend/zend_execute.c:2825
No locals.
#14 0x01039b77 in execute (op_array=0x86e306c)
at /net/jedi/local/php/5.0/Zend/zend_execute.c:1400
execute_data = {opline = 0x86ee780, function_state = {
function_symbol_table = 0x870e404, function = 0x872a444, reserved =
{0x100f260,
  0x86e3364, 0xbff36970, 0x0}}, fbc = 0x872a444, fbc_constructor =
0x0,
  op_array = 0x86e306c, object = 0x86efb2c, Ts = 0xbff33430,
  original_in_execution = 0 '\0', calling_scope = 0x86f0a54,
prev_execute_data = 0x0}
#15 0x01018b25 in zend_execute_scripts (type=8, retval=0x0,
file_count=3)
at /net/jedi/local/php/5.0/Zend/zend.c:1069
files = 0xbff34764 ""
i = 1
file_handle = (zend_file_handle *) 0xbff36970
orig_op_array = (zend_op_array *) 0x0
local_retval = (zval *) 0x0




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

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


#32862 [Opn->Bgs]: session_register() causes Segmentation fault

2005-04-30 Thread tony2001
 ID:   32862
 Updated by:   [EMAIL PROTECTED]
 Reported By:  svenl at haberer-online dot de
-Status:   Open
+Status:   Bogus
 Bug Type: Session related
 Operating System: SUSE Linux 9.2
 PHP Version:  4.3.11
 New Comment:

>Might there be some incompatibility ? 

Yes, of course.
Where did you get that extensions compiled with one PHP version will
work with another one?


Previous Comments:


[2005-04-30 23:13:23] svenl at haberer-online dot de

Hi Sniper, 
 
thanX for your quick reply...  
 
Sorry about not mentioning this earlier, but my 
session-support is inside an extension... 
 
Thus using exactly the same configure command for 4.3.10, 
sessions work fine (with register_globals = On, obviously). 
 
Perhaps the output of php_info helps: 
www.haberer-online.de/php/php4_3_10_info.htm 
www.haberer-online.de/php/php4_3_11_info.htm 
 
These are the two programs I use for testing: 
 
/// snip : session_test.php // 
 
Next 
 end session_test.php // 
 
/// snip : session_test2.php // 
"; 
echo "date=".date("H:i:s",time()); 
?> 
 end session_test2.php // 
 
with version 4.3.10, no errors get reported and the value 
set in the first script is reported in the second script... 
 
With v 4.3.11 I get the mentioned error messages. 
 
BTW, the only things I did was  
configure 
make 
make install  
- the extensions were not touched. Might there be some 
incompatibility ? 
 
The content of my extension dir looks like: 
ikarus: # pwd 
/usr/lib/php/extensions 
ikarus: # ll 
total 320 
drwxr-xr-x  2 root root   224 Mar 20 23:00 . 
drwxr-xr-x  5 root root   160 Mar 20 23:39 .. 
-rwxr-xr-x  1 root root 15426 Oct  5  2004 bz2.so 
-rwxr-xr-x  1 root root 36096 Oct  5  2004 curl.so 
-rwxr-xr-x  1 root root 43584 Oct  5  2004 ftp.so 
-rwxr-xr-x  1 root root 93311 Oct  5  2004 gd.so 
-rwxr-xr-x  1 root root 49578 Oct  5  2004 mysql.so 
-rwxr-xr-x  1 root root 52726 Oct  5  2004 session.so 
-rwxr-xr-x  1 root root 28486 Oct  5  2004 zlib.so 
 
ThanX again for your assistance - hope its not a stupid 
mistake from my side... 
 
Sven



[2005-04-28 08:28:40] [EMAIL PROTECTED]

It can hardly work if you have '--disable-session' in your configure
line. 



[2005-04-28 02:32:53] svenl at haberer-online dot de

Actually the same problem exists if 
register_globals = Off



[2005-04-28 02:22:23] svenl at haberer-online dot de

Description:

Hi,

when calling session_register() using php 4.3.11 and apache 2.0.50, I
get an Seg-Fault.

When using $_SESSION, it works fine

Using php 4.3.10 and exactly the same configuration, it worked fine.

my config looks as follows:
 ./configure --prefix=/usr --datadir=/usr/share/php
--mandir=/usr/share/man --bindir=/usr/bin --libdir=/usr/share
--includedir=/usr/include --sysconfdir=/etc --with-_lib=lib
--with-config-file-path=/etc --with-exec-dir=/usr/lib/php/bin
--disable-debug --enable-inline-optimization --enable-memory-limit
--enable-magic-quotes --enable-safe-mode --enable-sigchild
--disable-ctype --disable-session --without-mysql --disable-cli
--without-pear --with-openssl --with-apxs2=/usr/sbin/apxs2-prefork
i586-suse-linux --with-unixODBC=/usr/lib/unixODBC  

php-ini:
register_globals = On


Reproduce code:
---
Script 1: crashes



Script 2: works



Expected result:

both times I expect the time to be displayed

Actual result:
--
With the first script the browser shows nothing (FireFox) or complains
that the server closed the connection (Konqueror). 

Also apache adds the following warning to the error_log:
[date] [notice] child pid 30727 exit signal Segmentation fault (11)

---

The second script shows the time as expected





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


#32901 [Opn->Bgs]: ldap option conflicts with oracle instant client option

2005-04-30 Thread tony2001
 ID:   32901
 Updated by:   [EMAIL PROTECTED]
 Reported By:  bjstanik at in dot nextra dot sk
-Status:   Open
+Status:   Bogus
 Bug Type: LDAP related
 Operating System: linux gentoo
 PHP Version:  4.3.11
 New Comment:

We cannot fix problems of third party libraries.


Previous Comments:


[2005-04-30 17:44:28] bjstanik at in dot nextra dot sk

Description:

when I compile mod_php with ldap and instant oracle client support
ldap_connect() does not return any value. Oracle client works
correctly. Without oracle client support ldap works fine.






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


#32934 [Opn->Bgs]: Files with the PHP Extension execute with "/" instead of "." running the Script

2005-05-04 Thread tony2001
 ID:   32934
 Updated by:   [EMAIL PROTECTED]
 Reported By:  bernardino_lopez at yahoo dot com
-Status:   Open
+Status:   Bogus
 Bug Type: *General Issues
 Operating System: Linux
 PHP Version:  4.3.11
 New Comment:

Not a PHP problem.
Configure your webserver properly.


Previous Comments:


[2005-05-03 23:18:30] bernardino_lopez at yahoo dot com

Description:

Open Any PHP Page and replace the "." of the File Extension by "/"

Example:

http://www.abc.com/phpinfo.php

Replace the URL Address for:

http://www.abc.com/phpinfo/php

The script is going to execute.

Reproduce code:
---
No code just replace your URL from the extension ".php" for "/php" 


Expected result:

Same page execution of the Original page.

Not sure if possible to parse extra parameters to any exposed script to
execute

Actual result:
--
Page execute regardles of the 

phpinfo.php
phpinfo/php

At this point looking for a major impact because in case of be able to
pass arbitrary commands to the script to execute will create major
security issue.

Best Regards Dinooz.






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


#32940 [Opn->Bgs]: PHP 5.0.4

2005-05-04 Thread tony2001
 ID:   32940
 Updated by:   [EMAIL PROTECTED]
 Reported By:  thebomani at homail dot com
-Status:   Open
+Status:   Bogus
 Bug Type: *General Issues
 Operating System: RedHAt Fedora 3
 PHP Version:  5.0.4
 New Comment:

Turn on register_globals and do RTFM.


Previous Comments:


[2005-05-04 05:50:27] thebomani at homail dot com

Description:

I have had more problems with PHP 5.0.4 that I can list. These problems
include php not passing varialbles to php files when the url has a ?
mark after the .php file. Please put version 5.0.3 back in the download
list.






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


#32949 [Fbk]: crash at session_start()

2005-05-05 Thread tony2001
 ID:   32949
 Updated by:   [EMAIL PROTECTED]
 Reported By:  artdesign at mail dot ru
 Status:   Feedback
 Bug Type: Session related
 Operating System: freebsd 4.9
 PHP Version:  4.3.11
 New Comment:

Turn off eAccelerator and try again.


Previous Comments:


[2005-05-05 08:04:33] [EMAIL PROTECTED]

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

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





[2005-05-05 06:39:24] artdesign at mail dot ru

Description:

after update from 4.3.10 to 4.3.11

when using EACCELERATOR with apache, apache says:

 EACCELERATOR: PHP crashed on opline 329 of session_start() at ...

this is a big product ( www.bitrix.com ) that use session_start() many
times.

when no accelerator just crashes and send the not a full web page with
message in log:
[notice] child pid 65920 exit signal Bus error (10) 

php Configure Command
  './configure' '--enable-versioning' '--enable-memory-limit'
'--with-layout=GNU' '--with-config-file-scan-dir=/usr/local/etc/php'
'--with-zlib-dir=/usr' '--with-zlib=yes' '--disable-all'
'--with-regex=php' '--with-apxs=/usr/local/sbin/apxs' '--disable-ipv6'
'--prefix=/usr/local' 'i386-portbld-freebsd4.9'  


Reproduce code:
---
session_start() 

Expected result:

apache crashes






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


#32934 [Bgs]: Files with the PHP Extension execute with "/" instead of "." running the Script

2005-05-05 Thread tony2001
 ID:   32934
 Updated by:   [EMAIL PROTECTED]
 Reported By:  bernardino_lopez at yahoo dot com
 Status:   Bogus
 Bug Type: *General Issues
 Operating System: Linux
 PHP Version:  4.3.11
 New Comment:

I realize that all except for you have heard about MultiViews
directive. 
Please read Apache's documentation and realize that this "issue" has
nothing to do with PHP.


Previous Comments:


[2005-05-04 19:53:27] bernardino_lopez at yahoo dot com

Do you realize that all the PHP Webserver's in the World need to be
configure properly then ???

I'm just surprised it executed, at this time noticed the performance of
the server have some degradation in speed, I wonder if multiple
mal-formed request can slow down the server in general. but I really
don't think is WebServer configuration is execution of any PHP Script.

Will dig more about it and find out if Windows based servers  reply the
same way.

Something that I noticed the execution does not affect when run the php
from the CLI.

Best Regards Dino.



[2005-05-04 18:34:13] [EMAIL PROTECTED]

Not a PHP problem.
Configure your webserver properly.



[2005-05-03 23:18:30] bernardino_lopez at yahoo dot com

Description:

Open Any PHP Page and replace the "." of the File Extension by "/"

Example:

http://www.abc.com/phpinfo.php

Replace the URL Address for:

http://www.abc.com/phpinfo/php

The script is going to execute.

Reproduce code:
---
No code just replace your URL from the extension ".php" for "/php" 


Expected result:

Same page execution of the Original page.

Not sure if possible to parse extra parameters to any exposed script to
execute

Actual result:
--
Page execute regardles of the 

phpinfo.php
phpinfo/php

At this point looking for a major impact because in case of be able to
pass arbitrary commands to the script to execute will create major
security issue.

Best Regards Dinooz.






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


#32952 [Opn->Bgs]: CLI Crash

2005-05-05 Thread tony2001
 ID:   32952
 Updated by:   [EMAIL PROTECTED]
 Reported By:  perciun dot andrei at gmail dot com
-Status:   Open
+Status:   Bogus
-Bug Type: Reproducible crash
+Bug Type: Unknown/Other Function
 Operating System: Windows XP SP2
 PHP Version:  5.0.4
 New Comment:

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

No crash here, just a syntax error.
Read the docs about ternary operator.


Previous Comments:


[2005-05-05 10:11:15] perciun dot andrei at gmail dot com

Description:

CLI crash with expression.



Reproduce code:
---
$last = ($last == $next? null);

Expected result:

Should be correct if statement.






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


#32942 [Opn->Bgs]: "CLI a rencontré un problème et doit fermer. Nous vous prions..."

2005-05-05 Thread tony2001
 ID:   32942
 Updated by:   [EMAIL PROTECTED]
 Reported By:  yelva03 at yahoo dot fr
-Status:   Open
+Status:   Bogus
 Bug Type: Unknown/Other Function
 Operating System: Windows XP Professionnal
 PHP Version:  5.0.4
 New Comment:

In English please.


Previous Comments:


[2005-05-04 09:43:50] yelva03 at yahoo dot fr

Description:

Ce message de Windows XP apparaît à l'exécution de go_pear.bat,
pear.bat et php_win.exe : "CLI a rencontré un problème et doit fermer.
Nous vous prions de nous excuser pour le désagrément encouru."
Ceci pendant la configuration de PHP manuellement comme module de
Apache2.






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


  1   2   3   4   5   6   7   8   9   10   >