Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

Stubbles Blog:
Do not trust the reflection API
Jan 28, 2008 @ 19:07:00

On the Stubbles blog, Frank Kleine offers some advice to developers looking to use the Reflection API - "don't trust it".

If you try to get informations about parameters from methods of internal classes - forget that. Examining several internal classes my key findings are: either there is no information about parameters available and the reflection API says the method does not have any parameters, or the information about the parameter is wrong.

He includes code examples along side the output from the script to illustrate his point.

tagged: reflection api class external internal pdo pdostatement

Link:

Stuart Herbert's Blog:
Investigating A PDO Segfault
Jun 29, 2006 @ 10:56:34

Most of the time, working with PDO is simple - fire up the right driver for what you need and you're all set. But sometimes, something's just not right, as Stuart Herbert found out. He's blogged about this experience in his latest entry.

I've been playing about with using PDO to work with mysql. Something's not quite right in there, and it's resulting in a segfault when I run some local unit tests.

PDO objects themselves are created and destroyed when I'd expect them to be, as the objects go out of scope. The problem is that the PDOStatement objects aren't doing the same. According to gdb, PDOStatement objects are only getting cleaned up when php_request_shutdown() runs; never before.

Surely we should be seeing PDOStatement objects being destroyed before their corresponding PDO object?

He finds that there are relly two problems at work here - persistence of PDOStatement objects and PDO objects' destruction before their corresponding PDOStatement objects.

He asks for any opinions on the matter from anyone with the experience out there to help squash these bugs.

tagged: pdo segfault debug pdostatement object pdo pdo segfault debug pdostatement object pdo

Link:

Stuart Herbert's Blog:
Investigating A PDO Segfault
Jun 29, 2006 @ 10:56:34

Most of the time, working with PDO is simple - fire up the right driver for what you need and you're all set. But sometimes, something's just not right, as Stuart Herbert found out. He's blogged about this experience in his latest entry.

I've been playing about with using PDO to work with mysql. Something's not quite right in there, and it's resulting in a segfault when I run some local unit tests.

PDO objects themselves are created and destroyed when I'd expect them to be, as the objects go out of scope. The problem is that the PDOStatement objects aren't doing the same. According to gdb, PDOStatement objects are only getting cleaned up when php_request_shutdown() runs; never before.

Surely we should be seeing PDOStatement objects being destroyed before their corresponding PDO object?

He finds that there are relly two problems at work here - persistence of PDOStatement objects and PDO objects' destruction before their corresponding PDOStatement objects.

He asks for any opinions on the matter from anyone with the experience out there to help squash these bugs.

tagged: pdo segfault debug pdostatement object pdo pdo segfault debug pdostatement object pdo

Link:


Trending Topics: