Edit report at https://bugs.php.net/bug.php?id=79270&edit=1
ID: 79270
Updated by: cmb@php.net
Reported by: martin dot aschenbrenner at erwinmueller dot de
Summary: segfault in libodbc.so.2.0.0 with
ReflectionFunction($functio)->getParameters()
-Status: Open
+Status: Feedback
Type: Bug
Package: PDO ODBC
Operating System: Linux Ubuntu 18.04 x86_64
PHP Version: 7.3.14
-Assigned To:
+Assigned To: cmb
Block user comment: N
Private report: N
New Comment:
I cannot reproduce this. If you're still experiencing this
segfault with any of the actively supported PHP versions[1], can
you please provide a backtrace[2]?
[1] <https://www.php.net/supported-versions.php>
[2] <https://bugs.php.net/bugs-generating-backtrace.php>
Previous Comments:
------------------------------------------------------------------------
[2020-02-13 11:22:14] martin dot aschenbrenner at erwinmueller dot de
Description:
------------
getting randomly (approximately each second request) following segfault:
kernel: php-fpm7.3[17905]: segfault at 860 ip 00007f7e4e77cec0 sp 00007ffdcda8b040 error 4 in
libodbc.so.2.0.0[7f7e4e765000+62000]
some strange behaviors:
- uncommenting line 17 fixes the issue.
- also execution someReflection() with same parameter and an even number of times the issue
doesn't occur.
additional info:
- libodbc1 package: 2.3.4-1.1ubuntu3
- php is executed by fpm
- affects php versions 7.1.33, 7.2.27, 7.3.14, 7.4.2 (not more tested)
Test script:
---------------
<?php
class Core {
public $conn;
public function __construct() {
$this->circularReference = $this;
}
public function connect() {
$this->conn = new PDO("odbc:mysql");
}
public $stm;
function createStm( string $foo ) {
$this->connect();
$this->stm = $this->conn->prepare("SELECT * FROM mytable");
// $this->stm = NULL;
}
}
function someReflection( $function ) {
$rParameters = (new \ReflectionFunction($function))->getParameters();
}
someReflection("implode");
$app = new Core;
$app->createStm("bar");
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=79270&edit=1