#37822 [NEW]: Using PDO from CLI script results in seg fault
| From: | toolbag at gmail dot com | Date: | Thu, 15 Jun 2006 23:13:53 +0000 |
| Subject: | #37822 [NEW]: Using PDO from CLI script results in seg fault | ||
| Groups: | php.bugs | ||
| Request: | Send a blank email to php-bugs+get-98402@lists.php.net to get a copy of this message | ||
From: toolbag at gmail dot com
Operating system: GNU/Linux kernel 2.4.21
PHP version: 5.1.4
PHP Bug Type: Reproducible crash
Bug description: Using PDO from CLI script results in seg fault
Description:
------------
Instantiating a PDO object from a PHP script that is called from the CLI
results in a seg fault. Running the same script from a browser is
perfectly ok. I am using PDO + PDO_OCI in a large web app with no
problems, but when I coded up some PDO/OCI code to run within a cronjob,
this happens.
Reproduce code:
---------------
<?php
try {
$dbh = new PDO("oci:dbname=<host>", "<user>",
"<pass>");
}catch(PDOException $e) {
die("Error: " . $e->getMessage() );
}
$dbh = null;
echo "I am never reached";
?>
Expected result:
----------------
From the browser I see: "I am never reached".
From the CLI: immediate seg fault.
--
Edit bug report at http://bugs.php.net/?id=37822&edit=1
--
Try a CVS snapshot (PHP 4.4): http://bugs.php.net/fix.php?id=37822&r=trysnapshot44
Try a CVS snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=37822&r=trysnapshot52
Try a CVS snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=37822&r=trysnapshot60
Fixed in CVS: http://bugs.php.net/fix.php?id=37822&r=fixedcvs
Fixed in release: http://bugs.php.net/fix.php?id=37822&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=37822&r=needtrace
Need Reproduce Script: http://bugs.php.net/fix.php?id=37822&r=needscript
Try newer version: http://bugs.php.net/fix.php?id=37822&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=37822&r=support
Expected behavior: http://bugs.php.net/fix.php?id=37822&r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=37822&r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=37822&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=37822&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=37822&r=php3
Daylight Savings: http://bugs.php.net/fix.php?id=37822&r=dst
IIS Stability: http://bugs.php.net/fix.php?id=37822&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=37822&r=gnused
Floating point limitations: http://bugs.php.net/fix.php?id=37822&r=float
No Zend Extensions: http://bugs.php.net/fix.php?id=37822&r=nozend
MySQL Configuration Error: http://bugs.php.net/fix.php?id=37822&r=mysqlcfg