#42994 [Opn]: is_callable and __autoload

2007-10-17 Thread arnout at argeweb dot nl
 ID:   42994
 User updated by:  arnout at argeweb dot nl
 Reported By:  arnout at argeweb dot nl
 Status:   Open
 Bug Type: Unknown/Other Function
 Operating System: BSD
 PHP Version:  5.2.4
 New Comment:

I tried both 5.2.3 and 5.2.4.

5.2.3:

apache_mod on apache 2.0, FreeBSD 6.2-RELEASE-p5, can't turn zend
optimizer off there.


5.2.4:

Tried with Zend optimizer on and off.
php 5.2.4 apache_mod on apache 2.2
OS: FreeBSD 6.2-RELEASE-p3

'./configure' '--with-layout=GNU'
'--with-config-file-scan-dir=/usr/local/etc/php' '--disable-all'
'--enable-libxml' '--with-libxml-dir=/usr/local' '--enable-reflection'
'--program-prefix=' '--disable-cgi' '--with-apxs2=/usr/local/sbin/apxs'
'--with-regex=php' '--with-zend-vm=CALL' '--disable-ipv6'
'--prefix=/usr/local' '--mandir=/usr/local/man'
'--infodir=/usr/local/info/'

I hope that helps...


Previous Comments:


[2007-10-16 20:12:15] crrodriguez at suse dot de

Your exact code works just fine here, it does not call __autoload at
all... what is your exact PHP version ?



[2007-10-16 15:22:20] arnout at argeweb dot nl

Description:

When using is_callable on non-existing static class functions
__autoload will be called twice with some encoded (and thus
non-existent) classname.


Reproduce code:
---
autoload.php
?php

class test{
function notest(){
}
}

function __autoload( $classname ){
echo let's require $classname!br/\n;
}

if( is_callable( array( 'test', 'test' ) ) ){
echo test::test exists.;
}else{
echo test::test doesn't exist.;
}

?

Expected result:

test::test doesn't exist.

(no __autoload execution at all)

Actual result:
--
let's require 9akf!
let's require 9akf!
test::test doesn't exist.





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


#42994 [Fbk-Opn]: is_callable and __autoload

2007-10-17 Thread arnout at argeweb dot nl
 ID:   42994
 User updated by:  arnout at argeweb dot nl
 Reported By:  arnout at argeweb dot nl
-Status:   Feedback
+Status:   Open
 Bug Type: Unknown/Other Function
 Operating System: BSD
 PHP Version:  5.2.4
 New Comment:

no FreeBSD patches or something

I asked the sysadmin.
It has probably been patched by ports. I'll try to get a clean version
but that might take a while.

I'll try the snapshot too.

If it's the freebsd ports that messes up where do I need to go to get
it fixed?


Previous Comments:


[2007-10-17 07:55:14] [EMAIL PROTECTED]

Please try using this CVS snapshot:

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

For Windows (installer):

  http://snaps.php.net/win32/php5.2-win32-installer-latest.msi

For me it works fine. Please make sure you're using proper source - no
FreeBSD patches or something.



[2007-10-17 07:22:20] arnout at argeweb dot nl

I tried both 5.2.3 and 5.2.4.

5.2.3:

apache_mod on apache 2.0, FreeBSD 6.2-RELEASE-p5, can't turn zend
optimizer off there.


5.2.4:

Tried with Zend optimizer on and off.
php 5.2.4 apache_mod on apache 2.2
OS: FreeBSD 6.2-RELEASE-p3

'./configure' '--with-layout=GNU'
'--with-config-file-scan-dir=/usr/local/etc/php' '--disable-all'
'--enable-libxml' '--with-libxml-dir=/usr/local' '--enable-reflection'
'--program-prefix=' '--disable-cgi' '--with-apxs2=/usr/local/sbin/apxs'
'--with-regex=php' '--with-zend-vm=CALL' '--disable-ipv6'
'--prefix=/usr/local' '--mandir=/usr/local/man'
'--infodir=/usr/local/info/'

I hope that helps...



[2007-10-16 20:12:15] crrodriguez at suse dot de

Your exact code works just fine here, it does not call __autoload at
all... what is your exact PHP version ?



[2007-10-16 15:22:20] arnout at argeweb dot nl

Description:

When using is_callable on non-existing static class functions
__autoload will be called twice with some encoded (and thus
non-existent) classname.


Reproduce code:
---
autoload.php
?php

class test{
function notest(){
}
}

function __autoload( $classname ){
echo let's require $classname!br/\n;
}

if( is_callable( array( 'test', 'test' ) ) ){
echo test::test exists.;
}else{
echo test::test doesn't exist.;
}

?

Expected result:

test::test doesn't exist.

(no __autoload execution at all)

Actual result:
--
let's require 9akf!
let's require 9akf!
test::test doesn't exist.





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


#42994 [NEW]: is_callable and __autoload

2007-10-16 Thread arnout at argeweb dot nl
From: arnout at argeweb dot nl
Operating system: BSD
PHP version:  5.2.4
PHP Bug Type: Unknown/Other Function
Bug description:  is_callable and __autoload

Description:

When using is_callable on non-existing static class functions __autoload
will be called twice with some encoded (and thus non-existent) classname.


Reproduce code:
---
autoload.php
?php

class test{
function notest(){
}
}

function __autoload( $classname ){
echo let's require $classname!br/\n;
}

if( is_callable( array( 'test', 'test' ) ) ){
echo test::test exists.;
}else{
echo test::test doesn't exist.;
}

?

Expected result:

test::test doesn't exist.

(no __autoload execution at all)

Actual result:
--
let's require 9akf!
let's require 9akf!
test::test doesn't exist.

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


#42559 [NEW]: $this leaks to scope of statically called method

2007-09-05 Thread arnout at argeweb dot nl
From: arnout at argeweb dot nl
Operating system: BSD
PHP version:  5.2.4
PHP Bug Type: Class/Object related
Bug description:  $this leaks to scope of statically called method

Description:

Within methods the $this variable seems to leak into the scope of
statically called methods. Even when the called static function is in an
entirely different class.
It only happens when the statically called method is not explicitly
defined as static.

Reproduce code:
---
?php

class instance{

var $test = 'test';

function do_thing(){
static_class::func();
}
}

// happens with and without the abstract keyword
abstract class static_class{

function func(){
echo 'output: '.$this-test.'br/';
echo 'class: '.get_class( $this ).'br/';
echo 'How did I get here?br/';
}

}

$instance = new instance();
$instance-do_thing();
? 

Expected result:

A warning telling me I shouldn't use $this in a static scope.
Or just a notice saying $this is not defined / not an object.

Actual result:
--
output: testbr/
class: instancebr/
How did I get here?br/

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


#36924 [NEW]: string concat

2006-03-30 Thread arnout at argeweb dot nl
From: arnout at argeweb dot nl
Operating system: FreeBSD 5.4-RELEASE-p11
PHP version:  5.1.2
PHP Bug Type: Scripting Engine problem
Bug description:  string concat

Description:

Using the following code leaks 32 bytes of memory.

$doe = 'yoyoyo';
echo john $doe;



PHP 5.1.2 (cli) (built: Feb 22 2006 16:17:32)
Copyright (c) 1997-2006 The PHP Group
Zend Engine v2.1.0, Copyright (c) 1998-2006 Zend Technologies
with Zend Extension Manager v1.0.10, Copyright (c) 2003-2006, by Zend
Technologies
with Zend Optimizer v3.0.0-Beta2, Copyright (c) 1998-2006, by Zend
Technologies


Reproduce code:
---
?php

@ob_end_flush(); // to be sure


function fake1( $string ){
echo kaas .$string;
}

function fake2( $string ){
echo kaas $string;
}

function fake3( $string ){
$string = kaas $string;
}

function fake4( $string ){
echo kaas $string asdf;
}


echo Pbfunction fake1/b/p;

for( $i = 0;$i  10; $i++ ){
echo Memory at .$i.: .memory_get_usage().Br\n;
fake1( string );
echo Memory at .$i.: .memory_get_usage().Br\n;
}

echo Pbfunction fake2/b/p;

for( $i = 0;$i  10; $i++ ){
echo Memory at .$i.: .memory_get_usage().Br\n;
fake2( string );
echo Memory at .$i.: .memory_get_usage().Br\n;
}

echo Pbfunction fake3/b/p;

for( $i = 0;$i  10; $i++ ){
echo Memory at .$i.: .memory_get_usage().Br\n;
fake3( string );
echo Memory at .$i.: .memory_get_usage().Br\n;
}

echo Pbfunction fake4/b/p;

for( $i = 0;$i  10; $i++ ){
echo Memory at .$i.: .memory_get_usage().Br\n;
fake4( string );
echo Memory at .$i.: .memory_get_usage().Br\n;
}


?

Expected result:

Hardly any change in memory usage.

Actual result:
--
function fake1
Memory at 0: 42920
kaas stringMemory at 0: 42984
Memory at 1: 42984
kaas stringMemory at 1: 42984
Memory at 2: 42984
kaas stringMemory at 2: 42984
Memory at 3: 42984
kaas stringMemory at 3: 42984
...etcetera... +64 bytes, only once.

function fake2
Memory at 0: 42984
kaas stringMemory at 0: 43000
Memory at 1: 43000
kaas stringMemory at 1: 43016
Memory at 2: 43016
kaas stringMemory at 2: 43032
Memory at 3: 43032
kaas stringMemory at 3: 43048
...etcetera... +16 bytes

function fake3
Memory at 0: 43144
Memory at 0: 43160
Memory at 1: 43160
Memory at 1: 43176
Memory at 2: 43176
Memory at 2: 43192
Memory at 3: 43192
Memory at 3: 43208
...etcetera... +16 bytes

function fake4
Memory at 0: 43304
kaas string asdfMemory at 0: 43328
Memory at 1: 43328
kaas string asdfMemory at 1: 43352
Memory at 2: 43352
kaas string asdfMemory at 2: 43376
...etcetera... +24 bytes

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


#36924 [Opn]: string concat

2006-03-30 Thread arnout at argeweb dot nl
 ID:   36924
 User updated by:  arnout at argeweb dot nl
 Reported By:  arnout at argeweb dot nl
 Status:   Open
 Bug Type: Scripting Engine problem
 Operating System: FreeBSD 5.4-RELEASE-p11
 PHP Version:  5.1.2
 New Comment:

Using the following code leaks 32 bytes of memory.

Cleaning up the demo-script while submitting this bug gave a clearer
image. The demo says it all.
Using unset() didn't change anything anywhere by the way.


Previous Comments:


[2006-03-30 15:54:06] arnout at argeweb dot nl

Description:

Using the following code leaks 32 bytes of memory.

$doe = 'yoyoyo';
echo john $doe;



PHP 5.1.2 (cli) (built: Feb 22 2006 16:17:32)
Copyright (c) 1997-2006 The PHP Group
Zend Engine v2.1.0, Copyright (c) 1998-2006 Zend Technologies
with Zend Extension Manager v1.0.10, Copyright (c) 2003-2006, by
Zend Technologies
with Zend Optimizer v3.0.0-Beta2, Copyright (c) 1998-2006, by Zend
Technologies


Reproduce code:
---
?php

@ob_end_flush(); // to be sure


function fake1( $string ){
echo kaas .$string;
}

function fake2( $string ){
echo kaas $string;
}

function fake3( $string ){
$string = kaas $string;
}

function fake4( $string ){
echo kaas $string asdf;
}


echo Pbfunction fake1/b/p;

for( $i = 0;$i  10; $i++ ){
echo Memory at .$i.: .memory_get_usage().Br\n;
fake1( string );
echo Memory at .$i.: .memory_get_usage().Br\n;
}

echo Pbfunction fake2/b/p;

for( $i = 0;$i  10; $i++ ){
echo Memory at .$i.: .memory_get_usage().Br\n;
fake2( string );
echo Memory at .$i.: .memory_get_usage().Br\n;
}

echo Pbfunction fake3/b/p;

for( $i = 0;$i  10; $i++ ){
echo Memory at .$i.: .memory_get_usage().Br\n;
fake3( string );
echo Memory at .$i.: .memory_get_usage().Br\n;
}

echo Pbfunction fake4/b/p;

for( $i = 0;$i  10; $i++ ){
echo Memory at .$i.: .memory_get_usage().Br\n;
fake4( string );
echo Memory at .$i.: .memory_get_usage().Br\n;
}


?

Expected result:

Hardly any change in memory usage.

Actual result:
--
function fake1
Memory at 0: 42920
kaas stringMemory at 0: 42984
Memory at 1: 42984
kaas stringMemory at 1: 42984
Memory at 2: 42984
kaas stringMemory at 2: 42984
Memory at 3: 42984
kaas stringMemory at 3: 42984
...etcetera... +64 bytes, only once.

function fake2
Memory at 0: 42984
kaas stringMemory at 0: 43000
Memory at 1: 43000
kaas stringMemory at 1: 43016
Memory at 2: 43016
kaas stringMemory at 2: 43032
Memory at 3: 43032
kaas stringMemory at 3: 43048
...etcetera... +16 bytes

function fake3
Memory at 0: 43144
Memory at 0: 43160
Memory at 1: 43160
Memory at 1: 43176
Memory at 2: 43176
Memory at 2: 43192
Memory at 3: 43192
Memory at 3: 43208
...etcetera... +16 bytes

function fake4
Memory at 0: 43304
kaas string asdfMemory at 0: 43328
Memory at 1: 43328
kaas string asdfMemory at 1: 43352
Memory at 2: 43352
kaas string asdfMemory at 2: 43376
...etcetera... +24 bytes





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


#36924 [Bgs]: string concat

2006-03-30 Thread arnout at argeweb dot nl
 ID:   36924
 User updated by:  arnout at argeweb dot nl
 Reported By:  arnout at argeweb dot nl
 Status:   Bogus
 Bug Type: Scripting Engine problem
 Operating System: FreeBSD 5.4-RELEASE-p11
 PHP Version:  5.1.2
 New Comment:

OK, I guess it's not a memory leak then.
But nevermind the name: This problem makes it impossible to write a
long running script, because it keeps growing until it dies of memory
shortage.

Is this suicide designed, or is it a bug?


Previous Comments:


[2006-03-30 16:07:00] [EMAIL PROTECTED]

Leaks are reported by the engine.
What you see is the way the engine works and this is not a bug/leak.



[2006-03-30 15:56:43] arnout at argeweb dot nl

Using the following code leaks 32 bytes of memory.

Cleaning up the demo-script while submitting this bug gave a clearer
image. The demo says it all.
Using unset() didn't change anything anywhere by the way.



[2006-03-30 15:54:06] arnout at argeweb dot nl

Description:

Using the following code leaks 32 bytes of memory.

$doe = 'yoyoyo';
echo john $doe;



PHP 5.1.2 (cli) (built: Feb 22 2006 16:17:32)
Copyright (c) 1997-2006 The PHP Group
Zend Engine v2.1.0, Copyright (c) 1998-2006 Zend Technologies
with Zend Extension Manager v1.0.10, Copyright (c) 2003-2006, by
Zend Technologies
with Zend Optimizer v3.0.0-Beta2, Copyright (c) 1998-2006, by Zend
Technologies


Reproduce code:
---
?php

@ob_end_flush(); // to be sure


function fake1( $string ){
echo kaas .$string;
}

function fake2( $string ){
echo kaas $string;
}

function fake3( $string ){
$string = kaas $string;
}

function fake4( $string ){
echo kaas $string asdf;
}


echo Pbfunction fake1/b/p;

for( $i = 0;$i  10; $i++ ){
echo Memory at .$i.: .memory_get_usage().Br\n;
fake1( string );
echo Memory at .$i.: .memory_get_usage().Br\n;
}

echo Pbfunction fake2/b/p;

for( $i = 0;$i  10; $i++ ){
echo Memory at .$i.: .memory_get_usage().Br\n;
fake2( string );
echo Memory at .$i.: .memory_get_usage().Br\n;
}

echo Pbfunction fake3/b/p;

for( $i = 0;$i  10; $i++ ){
echo Memory at .$i.: .memory_get_usage().Br\n;
fake3( string );
echo Memory at .$i.: .memory_get_usage().Br\n;
}

echo Pbfunction fake4/b/p;

for( $i = 0;$i  10; $i++ ){
echo Memory at .$i.: .memory_get_usage().Br\n;
fake4( string );
echo Memory at .$i.: .memory_get_usage().Br\n;
}


?

Expected result:

Hardly any change in memory usage.

Actual result:
--
function fake1
Memory at 0: 42920
kaas stringMemory at 0: 42984
Memory at 1: 42984
kaas stringMemory at 1: 42984
Memory at 2: 42984
kaas stringMemory at 2: 42984
Memory at 3: 42984
kaas stringMemory at 3: 42984
...etcetera... +64 bytes, only once.

function fake2
Memory at 0: 42984
kaas stringMemory at 0: 43000
Memory at 1: 43000
kaas stringMemory at 1: 43016
Memory at 2: 43016
kaas stringMemory at 2: 43032
Memory at 3: 43032
kaas stringMemory at 3: 43048
...etcetera... +16 bytes

function fake3
Memory at 0: 43144
Memory at 0: 43160
Memory at 1: 43160
Memory at 1: 43176
Memory at 2: 43176
Memory at 2: 43192
Memory at 3: 43192
Memory at 3: 43208
...etcetera... +16 bytes

function fake4
Memory at 0: 43304
kaas string asdfMemory at 0: 43328
Memory at 1: 43328
kaas string asdfMemory at 1: 43352
Memory at 2: 43352
kaas string asdfMemory at 2: 43376
...etcetera... +24 bytes





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


#36206 [Fbk-Opn]: LDAP in nsswitch.conf causes segfault when resolving hostnames in PHP

2006-02-01 Thread arnout at argeweb dot nl
 ID:   36206
 User updated by:  arnout at argeweb dot nl
 Reported By:  arnout at argeweb dot nl
-Status:   Feedback
+Status:   Open
 Bug Type: CGI related
 Operating System: freeBSD 5.4
 PHP Version:  5.1.2
 New Comment:

[EMAIL PROTECTED]: ~ $ host example.com
example.com has address 192.0.34.166

top works fine
ps aux works fine

No segfaults there...


Previous Comments:


[2006-02-01 12:33:42] [EMAIL PROTECTED]

Please try to run `top`, `ps aux` and `host example.com`.
Do they work fine or segfault too?
I'm asking because of this:
http://lists.freebsd.org/pipermail/freebsd-bugs/2004-April/006201.html



[2006-01-30 12:25:00] arnout at argeweb dot nl

This just in:

The script does not terminate. It ends like it's supposed to.

The segfault is put out when the scripts terminates. I don't know if
it's a child process that dies, or that the segfault resides in a
buffer untill termination or something.

[EMAIL PROTECTED]: / # echo ? echo gethostbyname( 'php.net' ); ? | php
64.246.30.37Segmentation fault (core dumped)

I seem to have judged to fast before. But still: I can't surpress this
error. It's ugly!



[2006-01-30 12:01:41] arnout at argeweb dot nl

status change



[2006-01-30 12:00:33] oersoep at gmail dot com

#0  0x in ?? ()
#1  0x292ff7a5 in ?? () from /usr/local/lib/nss_ldap.so.1
#2  0x2930a4c0 in ?? () from /usr/local/lib/nss_ldap.so.1
#3  0x2817d760 in ?? () from /libexec/ld-elf.so.1
#4  0x2817d5d8 in ?? () from /libexec/ld-elf.so.1
#5  0x292ff740 in ?? () from /usr/local/lib/nss_ldap.so.1
#6  0x28162730 in _rtld_error () from /libexec/ld-elf.so.1
#7  0x293086c9 in _fini () from /usr/local/lib/nss_ldap.so.1
#8  0x2816380b in find_symdef () from /libexec/ld-elf.so.1
#9  0x28163e6a in dlclose () from /libexec/ld-elf.so.1
#10 0x2845b53c in _nsdbtput () from /lib/libc.so.5
#11 0x2845aef0 in endhostent () from /lib/libc.so.5
#12 0x2845b5bb in _nsdbtput () from /lib/libc.so.5
#13 0x2847e1a5 in __cxa_finalize () from /lib/libc.so.5
#14 0x2847dec6 in exit () from /lib/libc.so.5
#15 0x08130cc5 in main ()



[2006-01-30 11:55:17] [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 for *NIX and
http://bugs.php.net/bugs-generating-backtrace-win32.php for Win32

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.





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

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


#36206 [Bgs-Opn]: LDAP in nsswitch.conf causes segfault when resolving hostnames in PHP

2006-02-01 Thread arnout at argeweb dot nl
 ID:   36206
 User updated by:  arnout at argeweb dot nl
 Reported By:  arnout at argeweb dot nl
-Status:   Bogus
+Status:   Open
 Bug Type: CGI related
 Operating System: freeBSD 5.4
 PHP Version:  5.1.2
 New Comment:

No bogus yet :)


Previous Comments:


[2006-02-01 16:27:37] arnout at argeweb dot nl

Tried it. Python works great. No segfaults here.

We tried python with AND without LDAP.

It's a different problem that looks the same.


[EMAIL PROTECTED]: ~ # python mysql.py
Traceback (most recent call last):
 File mysql.py, line 6, in ?
   db = test)
 File /usr/local/lib/python2.4/site-packages/MySQLdb/__init__.py,
line 66, in Connect
   return Connection(*args, **kwargs)
 File /usr/local/lib/python2.4/site-packages/MySQLdb/connections.py,
line 134, in __init__
   super(Connection, self).__init__(*args, **kwargs2)
_mysql_exceptions.OperationalError: (2005, Unknown MySQL server host
'dfgdfgdfg' (1))

[EMAIL PROTECTED]: ~ # python mysql.py
Traceback (most recent call last):
 File mysql.py, line 6, in ?
   db = test)
 File /usr/local/lib/python2.4/site-packages/MySQLdb/__init__.py,
line 66, in Connect
   return Connection(*args, **kwargs)
 File /usr/local/lib/python2.4/site-packages/MySQLdb/connections.py,
line 134, in __init__
   super(Connection, self).__init__(*args, **kwargs2)
_mysql_exceptions.OperationalError: (1130, Host 'nonexistenthost.nl'
is not allowed to connect to this MySQL server)



[2006-02-01 16:01:47] [EMAIL PROTECTED]

Here:
http://unix.derkeiler.com/Mailing-Lists/FreeBSD/stable/2005-11/0315.html
you can find that this problem also happens with Python on FreeBSD
(with the very same backtrace).
So it's not PHP problem, but some FreeBSD issue.



[2006-02-01 15:34:08] arnout at argeweb dot nl

[EMAIL PROTECTED]: ~ $ host example.com
example.com has address 192.0.34.166

top works fine
ps aux works fine

No segfaults there...



[2006-02-01 12:33:42] [EMAIL PROTECTED]

Please try to run `top`, `ps aux` and `host example.com`.
Do they work fine or segfault too?
I'm asking because of this:
http://lists.freebsd.org/pipermail/freebsd-bugs/2004-April/006201.html



[2006-01-30 12:25:00] arnout at argeweb dot nl

This just in:

The script does not terminate. It ends like it's supposed to.

The segfault is put out when the scripts terminates. I don't know if
it's a child process that dies, or that the segfault resides in a
buffer untill termination or something.

[EMAIL PROTECTED]: / # echo ? echo gethostbyname( 'php.net' ); ? | php
64.246.30.37Segmentation fault (core dumped)

I seem to have judged to fast before. But still: I can't surpress this
error. It's ugly!



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

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


#36206 [Bgs]: LDAP in nsswitch.conf causes segfault when resolving hostnames in PHP

2006-02-01 Thread arnout at argeweb dot nl
 ID:   36206
 User updated by:  arnout at argeweb dot nl
 Reported By:  arnout at argeweb dot nl
 Status:   Bogus
 Bug Type: CGI related
 Operating System: freeBSD 5.4
 PHP Version:  5.1.2
 New Comment:

Tried it. Python works great. No segfaults here.

We tried python with AND without LDAP.

It's a different problem that looks the same.


[EMAIL PROTECTED]: ~ # python mysql.py
Traceback (most recent call last):
 File mysql.py, line 6, in ?
   db = test)
 File /usr/local/lib/python2.4/site-packages/MySQLdb/__init__.py,
line 66, in Connect
   return Connection(*args, **kwargs)
 File /usr/local/lib/python2.4/site-packages/MySQLdb/connections.py,
line 134, in __init__
   super(Connection, self).__init__(*args, **kwargs2)
_mysql_exceptions.OperationalError: (2005, Unknown MySQL server host
'dfgdfgdfg' (1))

[EMAIL PROTECTED]: ~ # python mysql.py
Traceback (most recent call last):
 File mysql.py, line 6, in ?
   db = test)
 File /usr/local/lib/python2.4/site-packages/MySQLdb/__init__.py,
line 66, in Connect
   return Connection(*args, **kwargs)
 File /usr/local/lib/python2.4/site-packages/MySQLdb/connections.py,
line 134, in __init__
   super(Connection, self).__init__(*args, **kwargs2)
_mysql_exceptions.OperationalError: (1130, Host 'nonexistenthost.nl'
is not allowed to connect to this MySQL server)


Previous Comments:


[2006-02-01 16:01:47] [EMAIL PROTECTED]

Here:
http://unix.derkeiler.com/Mailing-Lists/FreeBSD/stable/2005-11/0315.html
you can find that this problem also happens with Python on FreeBSD
(with the very same backtrace).
So it's not PHP problem, but some FreeBSD issue.



[2006-02-01 15:34:08] arnout at argeweb dot nl

[EMAIL PROTECTED]: ~ $ host example.com
example.com has address 192.0.34.166

top works fine
ps aux works fine

No segfaults there...



[2006-02-01 12:33:42] [EMAIL PROTECTED]

Please try to run `top`, `ps aux` and `host example.com`.
Do they work fine or segfault too?
I'm asking because of this:
http://lists.freebsd.org/pipermail/freebsd-bugs/2004-April/006201.html



[2006-01-30 12:25:00] arnout at argeweb dot nl

This just in:

The script does not terminate. It ends like it's supposed to.

The segfault is put out when the scripts terminates. I don't know if
it's a child process that dies, or that the segfault resides in a
buffer untill termination or something.

[EMAIL PROTECTED]: / # echo ? echo gethostbyname( 'php.net' ); ? | php
64.246.30.37Segmentation fault (core dumped)

I seem to have judged to fast before. But still: I can't surpress this
error. It's ugly!



[2006-01-30 12:01:41] arnout at argeweb dot nl

status change



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

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


#36206 [NEW]: LDAP in nsswitch.conf causes segfault when resolving hostnames in PHP

2006-01-30 Thread arnout at argeweb dot nl
From: arnout at argeweb dot nl
Operating system: freeBSD 5.4
PHP version:  5.1.2
PHP Bug Type: CGI related
Bug description:  LDAP in nsswitch.conf causes segfault when resolving 
hostnames in PHP

Description:

Any hostname resolve in PHP causes a segmentation fault.

It only happens when this file contains the ldap keyword.
When removed, everything works fine.

Everything works great when using modphp. It only happens when using the
executable.

[EMAIL PROTECTED]: / # cat /etc/nsswitch.conf
group: files ldap
group_compat: nis
hosts: files dns
networks: files
passwd: files
passwd_compat: nis
shells: files

We've seen it on two seperate systems.
It's on PHP versions 5.0.5, 5.1.1 and 5.1.2

Server #1:
openldap 2.2.30
nss_ldap 1.244
php 5.0.5
FreeBSD 5.4-RELEASE-p8

Server #2:
nss_ldap-1.239
openldap-client-2.2.27
php 5.1.2
FreeBSD 5.4-RELEASE-p8


Reproduce code:
---
[EMAIL PROTECTED]: / # echo ? echo gethostbyname('php.net'); ? | php

[EMAIL PROTECTED]: / # echo ? mysql_connect( 'badgerbadger', '', '' ); ? |
php


#!/usr/local/bin/php
?php
// this
echo gethostbyname( 'php.net' );
// AND this too
mysql_connect( 'blahdieblah', '', '' );
// and anything that resolves.
?


Expected result:

An IP-address and an error because the mysql host doesn't exist.

Actual result:
--
Segmentation fault on any line that resolves a hostname.

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


#36206 [Fbk-Opn]: LDAP in nsswitch.conf causes segfault when resolving hostnames in PHP

2006-01-30 Thread arnout at argeweb dot nl
 ID:   36206
 User updated by:  arnout at argeweb dot nl
 Reported By:  arnout at argeweb dot nl
-Status:   Feedback
+Status:   Open
 Bug Type: CGI related
 Operating System: freeBSD 5.4
 PHP Version:  5.1.2
 New Comment:

status change


Previous Comments:


[2006-01-30 12:00:33] oersoep at gmail dot com

#0  0x in ?? ()
#1  0x292ff7a5 in ?? () from /usr/local/lib/nss_ldap.so.1
#2  0x2930a4c0 in ?? () from /usr/local/lib/nss_ldap.so.1
#3  0x2817d760 in ?? () from /libexec/ld-elf.so.1
#4  0x2817d5d8 in ?? () from /libexec/ld-elf.so.1
#5  0x292ff740 in ?? () from /usr/local/lib/nss_ldap.so.1
#6  0x28162730 in _rtld_error () from /libexec/ld-elf.so.1
#7  0x293086c9 in _fini () from /usr/local/lib/nss_ldap.so.1
#8  0x2816380b in find_symdef () from /libexec/ld-elf.so.1
#9  0x28163e6a in dlclose () from /libexec/ld-elf.so.1
#10 0x2845b53c in _nsdbtput () from /lib/libc.so.5
#11 0x2845aef0 in endhostent () from /lib/libc.so.5
#12 0x2845b5bb in _nsdbtput () from /lib/libc.so.5
#13 0x2847e1a5 in __cxa_finalize () from /lib/libc.so.5
#14 0x2847dec6 in exit () from /lib/libc.so.5
#15 0x08130cc5 in main ()



[2006-01-30 11:55:17] [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 for *NIX and
http://bugs.php.net/bugs-generating-backtrace-win32.php for Win32

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.





[2006-01-30 11:41:10] arnout at argeweb dot nl

Description:

Any hostname resolve in PHP causes a segmentation fault.

It only happens when this file contains the ldap keyword.
When removed, everything works fine.

Everything works great when using modphp. It only happens when using
the executable.

[EMAIL PROTECTED]: / # cat /etc/nsswitch.conf
group: files ldap
group_compat: nis
hosts: files dns
networks: files
passwd: files
passwd_compat: nis
shells: files

We've seen it on two seperate systems.
It's on PHP versions 5.0.5, 5.1.1 and 5.1.2

Server #1:
openldap 2.2.30
nss_ldap 1.244
php 5.0.5
FreeBSD 5.4-RELEASE-p8

Server #2:
nss_ldap-1.239
openldap-client-2.2.27
php 5.1.2
FreeBSD 5.4-RELEASE-p8


Reproduce code:
---
[EMAIL PROTECTED]: / # echo ? echo gethostbyname('php.net'); ? | php

[EMAIL PROTECTED]: / # echo ? mysql_connect( 'badgerbadger', '', '' ); ? |
php


#!/usr/local/bin/php
?php
// this
echo gethostbyname( 'php.net' );
// AND this too
mysql_connect( 'blahdieblah', '', '' );
// and anything that resolves.
?


Expected result:

An IP-address and an error because the mysql host doesn't exist.

Actual result:
--
Segmentation fault on any line that resolves a hostname.





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


#36206 [Opn]: LDAP in nsswitch.conf causes segfault when resolving hostnames in PHP

2006-01-30 Thread arnout at argeweb dot nl
 ID:   36206
 User updated by:  arnout at argeweb dot nl
 Reported By:  arnout at argeweb dot nl
 Status:   Open
 Bug Type: CGI related
 Operating System: freeBSD 5.4
 PHP Version:  5.1.2
 New Comment:

This just in:

The script does not terminate. It ends like it's supposed to.

The segfault is put out when the scripts terminates. I don't know if
it's a child process that dies, or that the segfault resides in a
buffer untill termination or something.

[EMAIL PROTECTED]: / # echo ? echo gethostbyname( 'php.net' ); ? | php
64.246.30.37Segmentation fault (core dumped)

I seem to have judged to fast before. But still: I can't surpress this
error. It's ugly!


Previous Comments:


[2006-01-30 12:01:41] arnout at argeweb dot nl

status change



[2006-01-30 12:00:33] oersoep at gmail dot com

#0  0x in ?? ()
#1  0x292ff7a5 in ?? () from /usr/local/lib/nss_ldap.so.1
#2  0x2930a4c0 in ?? () from /usr/local/lib/nss_ldap.so.1
#3  0x2817d760 in ?? () from /libexec/ld-elf.so.1
#4  0x2817d5d8 in ?? () from /libexec/ld-elf.so.1
#5  0x292ff740 in ?? () from /usr/local/lib/nss_ldap.so.1
#6  0x28162730 in _rtld_error () from /libexec/ld-elf.so.1
#7  0x293086c9 in _fini () from /usr/local/lib/nss_ldap.so.1
#8  0x2816380b in find_symdef () from /libexec/ld-elf.so.1
#9  0x28163e6a in dlclose () from /libexec/ld-elf.so.1
#10 0x2845b53c in _nsdbtput () from /lib/libc.so.5
#11 0x2845aef0 in endhostent () from /lib/libc.so.5
#12 0x2845b5bb in _nsdbtput () from /lib/libc.so.5
#13 0x2847e1a5 in __cxa_finalize () from /lib/libc.so.5
#14 0x2847dec6 in exit () from /lib/libc.so.5
#15 0x08130cc5 in main ()



[2006-01-30 11:55:17] [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 for *NIX and
http://bugs.php.net/bugs-generating-backtrace-win32.php for Win32

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.





[2006-01-30 11:41:10] arnout at argeweb dot nl

Description:

Any hostname resolve in PHP causes a segmentation fault.

It only happens when this file contains the ldap keyword.
When removed, everything works fine.

Everything works great when using modphp. It only happens when using
the executable.

[EMAIL PROTECTED]: / # cat /etc/nsswitch.conf
group: files ldap
group_compat: nis
hosts: files dns
networks: files
passwd: files
passwd_compat: nis
shells: files

We've seen it on two seperate systems.
It's on PHP versions 5.0.5, 5.1.1 and 5.1.2

Server #1:
openldap 2.2.30
nss_ldap 1.244
php 5.0.5
FreeBSD 5.4-RELEASE-p8

Server #2:
nss_ldap-1.239
openldap-client-2.2.27
php 5.1.2
FreeBSD 5.4-RELEASE-p8


Reproduce code:
---
[EMAIL PROTECTED]: / # echo ? echo gethostbyname('php.net'); ? | php

[EMAIL PROTECTED]: / # echo ? mysql_connect( 'badgerbadger', '', '' ); ? |
php


#!/usr/local/bin/php
?php
// this
echo gethostbyname( 'php.net' );
// AND this too
mysql_connect( 'blahdieblah', '', '' );
// and anything that resolves.
?


Expected result:

An IP-address and an error because the mysql host doesn't exist.

Actual result:
--
Segmentation fault on any line that resolves a hostname.





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


#29258 [Fbk-Csd]: conversion between unix timestamp and variant VT_date

2004-07-28 Thread arnout at argeweb dot nl
 ID:   29258
 User updated by:  arnout at argeweb dot nl
 Reported By:  arnout at argeweb dot nl
-Status:   Feedback
+Status:   Closed
 Bug Type: COM related
 Operating System: Windows 2003 server,standard
 PHP Version:  5.0.0
 New Comment:

Seems to be fixed in CVS. Thanks!


Previous Comments:


[2004-07-22 14:49:13] [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

Please try a snapshot.



[2004-07-19 15:19:43] arnout at argeweb dot nl

Description:

Converting dates using variant_date_from_timestamp() loses 2 hours. 
Might be some timezone-like thing but then again:
variant_date_to_timestamp() does give a precise translation.

I'm running apache 2 with php 5.0.0 RC 2. I tried both CGI and through
apache.

Reproduce code:
---
?

$nu = date('Ymd');
echo now: $nu\n;

$timestamp = mktime( 0, 0, 0, date('m'), date('d'), date('Y') );   //
Ymd = 2004 07 19
echo now timestamp: $timestamp\n;

echo a.k.a. : .$timestamp. = .date('Ymd', $timestamp ).\n;

$variant = variant_date_from_timestamp( $timestamp );
//$variant = variant_date_from_timestamp( time() );

echo variant: .$variant.\n;

$var_timestamp = variant_date_to_timestamp( $variant );
echo and back again: .$var_timestamp. = .date('Ymd', $var_timestamp
).\n;

?

Expected result:

now: 20040719
now timestamp: 1090188000
a.k.a. : 1090188000 = 20040719
variant: 19-7-2004 0:00:00
and back again: 1090188000 = 20040719


Actual result:
--
now: 20040719
now timestamp: 1090188000
a.k.a. : 1090188000 = 20040719
variant: 18-7-2004 22:00:00
and back again: 1090180800 = 20040718

// 2 hours gone! And even worse: The date changed!





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


#29258 [NEW]: conversion between unix timestamp and variant VT_date

2004-07-19 Thread arnout at argeweb dot nl
From: arnout at argeweb dot nl
Operating system: Windows 2003 server,standard
PHP version:  5.0.0
PHP Bug Type: COM related
Bug description:  conversion between unix timestamp and variant VT_date 

Description:

Converting dates using variant_date_from_timestamp() loses 2 hours. 
Might be some timezone-like thing but then again:
variant_date_to_timestamp() does give a precise translation.

I'm running apache 2 with php 5.0.0 RC 2. I tried both CGI and through
apache.

Reproduce code:
---
?

$nu = date('Ymd');
echo now: $nu\n;

$timestamp = mktime( 0, 0, 0, date('m'), date('d'), date('Y') );   // Ymd
= 2004 07 19
echo now timestamp: $timestamp\n;

echo a.k.a. : .$timestamp. = .date('Ymd', $timestamp ).\n;

$variant = variant_date_from_timestamp( $timestamp );
//$variant = variant_date_from_timestamp( time() );

echo variant: .$variant.\n;

$var_timestamp = variant_date_to_timestamp( $variant );
echo and back again: .$var_timestamp. = .date('Ymd', $var_timestamp
).\n;

?

Expected result:

now: 20040719
now timestamp: 1090188000
a.k.a. : 1090188000 = 20040719
variant: 19-7-2004 0:00:00
and back again: 1090188000 = 20040719


Actual result:
--
now: 20040719
now timestamp: 1090188000
a.k.a. : 1090188000 = 20040719
variant: 18-7-2004 22:00:00
and back again: 1090180800 = 20040718

// 2 hours gone! And even worse: The date changed!

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


#28179 [Fbk-Opn]: [COM] passing classes as a parameter

2004-05-03 Thread arnout at argeweb dot nl
 ID:   28179
 User updated by:  arnout at argeweb dot nl
 Reported By:  arnout at argeweb dot nl
-Status:   Feedback
+Status:   Open
 Bug Type: COM related
 Operating System: Windows NT 5.2 / Windows 2003
 PHP Version:  PHP Version 5.0.0RC2
 New Comment:

I've got it running now too. It only works if you import the DLL like
'event classes' instead of 'components'.

The real DLL by the way didn't work until I removed it all from the
COM+ manager and run regsvr32.exe on it.


Previous Comments:


[2004-04-30 11:45:36] [EMAIL PROTECTED]

What user account is Apache running under?
Does it make a difference if you run it as a different user?



[2004-04-29 16:45:39] arnout at argeweb dot nl

I'm using Apache 2 and run 5.0.0RC2 as a module. Maybe that makes some
difference?

$Administration = new COM(PHPTest.Administration) or die(huh?);
$Customer = new COM(PHPTest.Customer) or die(what?);
echo $Customer-Connect( $Administration ); // Huge error



[2004-04-29 16:12:20] [EMAIL PROTECTED]

The test materials you supplied worked just fine.




[2004-04-29 15:14:47] arnout at argeweb dot nl

The problem's still there. 

Fatal error: Uncaught exception 'com_exception' with message 'Source:
PHPTest
Description: Can not call friend function on object which is not an
instance of defining class' in C:\Program Files\Apache
Group\Apache2\htdocs\phptest.php:32 Stack trace: #0 {main} thrown in
C:\Program Files\Apache Group\Apache2\htdocs\phptest.php on line 32



[2004-04-28 17:12:42] [EMAIL PROTECTED]

Maybe its about time I read the version field of this report.

This problem won't be fixed in PHP 4, but already works just fine in
PHP 5.



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

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


#28179 [WFx]: [COM] passing classes as a parameter

2004-04-29 Thread arnout at argeweb dot nl
 ID:   28179
 User updated by:  arnout at argeweb dot nl
 Reported By:  arnout at argeweb dot nl
 Status:   Wont fix
 Bug Type: COM related
 Operating System: Windows NT 5.2 / Windows 2003
-PHP Version:  4.3.6
+PHP Version:  PHP Version 5.0.0RC2
 New Comment:

The problem's still there. 

Fatal error: Uncaught exception 'com_exception' with message 'Source:
PHPTest
Description: Can not call friend function on object which is not an
instance of defining class' in C:\Program Files\Apache
Group\Apache2\htdocs\phptest.php:32 Stack trace: #0 {main} thrown in
C:\Program Files\Apache Group\Apache2\htdocs\phptest.php on line 32


Previous Comments:


[2004-04-28 17:12:42] [EMAIL PROTECTED]

Maybe its about time I read the version field of this report.

This problem won't be fixed in PHP 4, but already works just fine in
PHP 5.



[2004-04-28 13:30:39] arnout at argeweb dot nl

I received the DLL and the error's still there.

http://www.argeweb.nl/php/PHPTest.zip

This file contains the DLL, the sourcecodes, an example and a readme.
No IDL but I think this might be even better.



[2004-04-28 11:11:39] [EMAIL PROTECTED]

The IDL describes what the method looks like to other COM applications;
I need it to see what their object expects and help deduce what might
be going wrong.




[2004-04-28 09:39:46] arnout at argeweb dot nl

I've talked to them. They said an IDL wouldn't do much good because IDL
doesn't contain friend functions, only publics.

They offered to create a sober Hello world DLL in VB which simulates
the case. I'll test again when I get it. If the error occurs again I'll
send you the source code + compiled version.

Is that of use to you?



[2004-04-27 19:52:30] [EMAIL PROTECTED]

It could easily be a PHP problem.
Could you paste the IDL for the method in question here please, so that
I can make a similar COM object here to
test against.
If you're unsure about how to get it, ask the people
that made the DLL.



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

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


#28179 [Fbk-Opn]: [COM] passing classes as a parameter

2004-04-29 Thread arnout at argeweb dot nl
 ID:   28179
 User updated by:  arnout at argeweb dot nl
 Reported By:  arnout at argeweb dot nl
-Status:   Feedback
+Status:   Open
 Bug Type: COM related
 Operating System: Windows NT 5.2 / Windows 2003
 PHP Version:  PHP Version 5.0.0RC2
 New Comment:

I'm using Apache 2 and run 5.0.0RC2 as a module. Maybe that makes some
difference?

$Administration = new COM(PHPTest.Administration) or die(huh?);
$Customer = new COM(PHPTest.Customer) or die(what?);
echo $Customer-Connect( $Administration ); // Huge error


Previous Comments:


[2004-04-29 16:12:20] [EMAIL PROTECTED]

The test materials you supplied worked just fine.




[2004-04-29 15:14:47] arnout at argeweb dot nl

The problem's still there. 

Fatal error: Uncaught exception 'com_exception' with message 'Source:
PHPTest
Description: Can not call friend function on object which is not an
instance of defining class' in C:\Program Files\Apache
Group\Apache2\htdocs\phptest.php:32 Stack trace: #0 {main} thrown in
C:\Program Files\Apache Group\Apache2\htdocs\phptest.php on line 32



[2004-04-28 17:12:42] [EMAIL PROTECTED]

Maybe its about time I read the version field of this report.

This problem won't be fixed in PHP 4, but already works just fine in
PHP 5.



[2004-04-28 13:30:39] arnout at argeweb dot nl

I received the DLL and the error's still there.

http://www.argeweb.nl/php/PHPTest.zip

This file contains the DLL, the sourcecodes, an example and a readme.
No IDL but I think this might be even better.



[2004-04-28 11:11:39] [EMAIL PROTECTED]

The IDL describes what the method looks like to other COM applications;
I need it to see what their object expects and help deduce what might
be going wrong.




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

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


#28179 [Fbk-Opn]: passing classes as a parameter

2004-04-28 Thread arnout at argeweb dot nl
 ID:   28179
 User updated by:  arnout at argeweb dot nl
 Reported By:  arnout at argeweb dot nl
-Status:   Feedback
+Status:   Open
 Bug Type: COM related
 Operating System: Windows NT 5.2 / Windows 2003
 PHP Version:  4.3.6
 New Comment:

I've talked to them. They said an IDL wouldn't do much good because IDL
doesn't contain friend functions, only publics.

They offered to create a sober Hello world DLL in VB which simulates
the case. I'll test again when I get it. If the error occurs again I'll
send you the source code + compiled version.

Is that of use to you?


Previous Comments:


[2004-04-27 19:52:30] [EMAIL PROTECTED]

It could easily be a PHP problem.
Could you paste the IDL for the method in question here please, so that
I can make a similar COM object here to
test against.
If you're unsure about how to get it, ask the people
that made the DLL.



[2004-04-27 12:02:31] arnout at argeweb dot nl

Description:

I'm trying to pass a COM class into a member function of another COM
class object. The second object chokes.

One class is the connection with the database.
The second is something that needs to connect.

Reproduce code:
---

$Conn = new COM(some.Conn);
$Conn-Connect( 'database', 'user', 'pass');

// this object is works fine.

$Customer = new COM(some.Customer);
$Customer-Connect( $Conn );  // KLABAM!

Expected result:

I'd expect the $Customer-Connect() function to accept the $Conn as
being a Conn object and just connect.

Actual result:
--
Error number: 97
Error description: Can not call friend function on object which is not
an instance of defining class

This error comes from the object. 
The Customer-Connect function calls a friend function to do something
with the Conn object. This function does not believe the object is a
living Conn object and spittes it out.

The whole thing works perfectly in C, VC++, VB, Jscript, VBscript (ASP)
and Delphi.

I've called the company that made the DLL, and they think the Conn
object I pass isn't a real Conn object, but a simulation / emulation.
Or a COM object of course.

I've tried converting it to a more MS-like thing with the VARIANT
class, but it doesn't seem to do much good. (type mismatch)

So is this a PHP problem, or didn't the ones who made the DLL read the
COM specifications too well?





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


#28179 [Fbk-Opn]: [COM] passing classes as a parameter

2004-04-28 Thread arnout at argeweb dot nl
 ID:   28179
 User updated by:  arnout at argeweb dot nl
 Reported By:  arnout at argeweb dot nl
-Status:   Feedback
+Status:   Open
 Bug Type: COM related
 Operating System: Windows NT 5.2 / Windows 2003
 PHP Version:  4.3.6
 New Comment:

I received the DLL and the error's still there.

http://www.argeweb.nl/php/PHPTest.zip

This file contains the DLL, the sourcecodes, an example and a readme.
No IDL but I think this might be even better.


Previous Comments:


[2004-04-28 11:11:39] [EMAIL PROTECTED]

The IDL describes what the method looks like to other COM applications;
I need it to see what their object expects and help deduce what might
be going wrong.




[2004-04-28 09:39:46] arnout at argeweb dot nl

I've talked to them. They said an IDL wouldn't do much good because IDL
doesn't contain friend functions, only publics.

They offered to create a sober Hello world DLL in VB which simulates
the case. I'll test again when I get it. If the error occurs again I'll
send you the source code + compiled version.

Is that of use to you?



[2004-04-27 19:52:30] [EMAIL PROTECTED]

It could easily be a PHP problem.
Could you paste the IDL for the method in question here please, so that
I can make a similar COM object here to
test against.
If you're unsure about how to get it, ask the people
that made the DLL.



[2004-04-27 12:02:31] arnout at argeweb dot nl

Description:

I'm trying to pass a COM class into a member function of another COM
class object. The second object chokes.

One class is the connection with the database.
The second is something that needs to connect.

Reproduce code:
---

$Conn = new COM(some.Conn);
$Conn-Connect( 'database', 'user', 'pass');

// this object is works fine.

$Customer = new COM(some.Customer);
$Customer-Connect( $Conn );  // KLABAM!

Expected result:

I'd expect the $Customer-Connect() function to accept the $Conn as
being a Conn object and just connect.

Actual result:
--
Error number: 97
Error description: Can not call friend function on object which is not
an instance of defining class

This error comes from the object. 
The Customer-Connect function calls a friend function to do something
with the Conn object. This function does not believe the object is a
living Conn object and spittes it out.

The whole thing works perfectly in C, VC++, VB, Jscript, VBscript (ASP)
and Delphi.

I've called the company that made the DLL, and they think the Conn
object I pass isn't a real Conn object, but a simulation / emulation.
Or a COM object of course.

I've tried converting it to a more MS-like thing with the VARIANT
class, but it doesn't seem to do much good. (type mismatch)

So is this a PHP problem, or didn't the ones who made the DLL read the
COM specifications too well?





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


#28179 [NEW]: passing classes as a parameter

2004-04-27 Thread arnout at argeweb dot nl
From: arnout at argeweb dot nl
Operating system: Windows NT 5.2 / Windows 2003
PHP version:  4.3.6
PHP Bug Type: COM related
Bug description:  passing classes as a parameter

Description:

I'm trying to pass a COM class into a member function of another COM class
object. The second object chokes.

One class is the connection with the database.
The second is something that needs to connect.

Reproduce code:
---

$Conn = new COM(some.Conn);
$Conn-Connect( 'database', 'user', 'pass');

// this object is works fine.

$Customer = new COM(some.Customer);
$Customer-Connect( $Conn );  // KLABAM!

Expected result:

I'd expect the $Customer-Connect() function to accept the $Conn as being
a Conn object and just connect.

Actual result:
--
Error number: 97
Error description: Can not call friend function on object which is not an
instance of defining class

This error comes from the object. 
The Customer-Connect function calls a friend function to do something
with the Conn object. This function does not believe the object is a
living Conn object and spittes it out.

The whole thing works perfectly in C, VC++, VB, Jscript, VBscript (ASP)
and Delphi.

I've called the company that made the DLL, and they think the Conn object
I pass isn't a real Conn object, but a simulation / emulation. Or a COM
object of course.

I've tried converting it to a more MS-like thing with the VARIANT class,
but it doesn't seem to do much good. (type mismatch)

So is this a PHP problem, or didn't the ones who made the DLL read the COM
specifications too well?

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