php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #72431 Segmentation fault 11
Submitted: 2016-06-16 13:53 UTC Modified: 2021-03-14 04:22 UTC
Votes:1
Avg. Score:3.0 ± 0.0
Reproduced:0 of 0 (0.0%)
From: attila dot perger at hu dot ibm dot com Assigned: cmb (profile)
Status: No Feedback Package: PDO_IBM (PECL)
PHP Version: Irrelevant OS: Mac OS X 10.7
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: attila dot perger at hu dot ibm dot com
New email:
PHP Version: OS:

 

 [2016-06-16 13:53 UTC] attila dot perger at hu dot ibm dot com
Description:
------------
The driver is loaded ("php -m"and/or "phpinfo()" show it with both versions), But when the code wants to connect to the DB, it fails with segmentation fault 11. The next code has no output at all. I have executed the code with the built in PHP 5.3.15 and with PHP 5.5.33 (build  according to the following page: http://php-osx.liip.ch).

Test script:
---------------
<?php

try {

  $user='??????';
  $password='xxxxxx';
  $connStr1 = "ibm:test01";
  $connStr2 = "ibm:DRIVER={IBM DB2 ODBC DRIVER};HOSTNAME=127.0.0.1;DATABASE=TEST01;";

  $option = array(
    PDO::ATTR_PERSISTENT => TRUE,
    PDO::ATTR_CASE => PDO::CASE_NATURAL,
    PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION
  );

  $conn = new PDO($connStr1, $user, $password, $option);
  // $conn = new PDO($connStr2, $user, $password); //, $option);

  echo "Connection is established... db: test01, user: aperger" . PHP_EOL;

  $attributes = array(
    "AUTOCOMMIT", "ERRMODE", "CASE", "CLIENT_VERSION", "CONNECTION_STATUS",
    "ORACLE_NULLS", "PERSISTENT", "PREFETCH", "SERVER_INFO", "SERVER_VERSION",
    "TIMEOUT"
  );

  foreach ($attributes as $val) {
    echo "PDO::ATTR_$val: ";
    echo $conn->getAttribute(constant("PDO::ATTR_$val")) . PHP_EOL;
  }

}
catch (Exception $e) {
  ($e->getMessage());
}

?>


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2021-03-03 12:52 UTC] cmb@php.net
-Status: Open +Status: Feedback -Assigned To: +Assigned To: cmb
 [2021-03-03 12:52 UTC] cmb@php.net
If that segfault is still reproducible with any of the actively
supported PHP versions[1] and the latest PDO_IBM, please provide a
stack backtrace[2].

[1] <https://www.php.net/supported-versions.php>
[2] <https://bugs.php.net/bugs-generating-backtrace.php>
 [2021-03-14 04:22 UTC] pecl-dev at lists dot php dot net
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 "Re-Opened". Thank you.
 
PHP Copyright © 2001-2021 The PHP Group
All rights reserved.
Last updated: Sun Sep 19 00:03:39 2021 UTC