Bug #77099 [NEW]: PHP crashes with segfault

From: Date: Sat, 03 Nov 2018 14:58:04 +0000
Subject: Bug #77099 [NEW]: PHP crashes with segfault
Groups: php.bugs 
Request: Send a blank email to php-bugs+get-217803@lists.php.net to get a copy of this message
From:             info at phpgangsta dot de
Operating system: Ubuntu 18.04
PHP version:      7.2.11
Package:          Pspell related
Bug Type:         Bug
Bug description:PHP crashes with segfault

Description:
------------
If I use pspell for spellchecking, it sometimes crashes with a segfault.
Every 3-5 times I call the script via Apache, Apache crashes:

[Sat Nov 03 15:36:12.592943 2018] [core:notice] [pid 5264] AH00051:
child pid 29189 exit signal Segmentation fault (11), possible coredump
in /etc/apache2
[Sat Nov 03 15:37:33.689349 2018] [core:notice] [pid 5264] AH00051:
child pid 29965 exit signal Segmentation fault (11), possible coredump
in /etc/apache2
[Sat Nov 03 15:40:12.879852 2018] [core:notice] [pid 5264] AH00051:
child pid 30367 exit signal Segmentation fault (11), possible coredump
in /etc/apache2

The small script below can reproduce the problem: If you call it from
outside via HTTP, it crashes every 3-5 requests:

curl https://url.de/spellchecker.php

See segmentation faults above.

$ php -v
PHP 7.2.11-3+ubuntu18.04.1+deb.sury.org+1 (cli) (built: Oct 25 2018
06:44:08) ( NTS )
Copyright (c) 1997-2018 The PHP Group
Zend Engine v3.2.0, Copyright (c) 1998-2018 Zend Technologies
    with Zend OPcache v7.2.11-3+ubuntu18.04.1+deb.sury.org+1, Copyright
(c) 1999-2018, by Zend Technologies


It seems to just happen with de_DE. If I change it to en_US, it does not
crash. Maybe it has to do with Umlauts oder similar?
Interestingly I'm not able to reproduce it on the command line...

Segmentation fault also happens on Ubuntu 16.04 with PHP 7.1:

$ php -v
PHP 7.1.23-3+ubuntu16.04.1+deb.sury.org+1 (cli) (built: Oct 25 2018
06:43:19) ( NTS )
Copyright (c) 1997-2018 The PHP Group
Zend Engine v3.1.0, Copyright (c) 1998-2018 Zend Technologies
    with Zend OPcache v7.1.23-3+ubuntu16.04.1+deb.sury.org+1, Copyright
(c) 1999-2018, by Zend Technologies

Test script:
---------------
<?php
$plink = pspell_new('de_DE', "", "", "utf-8", PSPELL_FAST);
pspell_suggest($plink, '___');

Expected result:
----------------
no crash

Actual result:
--------------
crash with segmentation fault

-- 
Edit bug report at https://bugs.php.net/bug.php?id=77099&edit=1
-- 
Try a snapshot (PHP 5.4):   https://bugs.php.net/fix.php?id=77099&r=trysnapshot54
Try a snapshot (PHP 5.5):   https://bugs.php.net/fix.php?id=77099&r=trysnapshot55
Try a snapshot (trunk):     https://bugs.php.net/fix.php?id=77099&r=trysnapshottrunk
Fixed in SVN:               https://bugs.php.net/fix.php?id=77099&r=fixed
Fixed in release:           https://bugs.php.net/fix.php?id=77099&r=alreadyfixed
Need backtrace:             https://bugs.php.net/fix.php?id=77099&r=needtrace
Need Reproduce Script:      https://bugs.php.net/fix.php?id=77099&r=needscript
Try newer version:          https://bugs.php.net/fix.php?id=77099&r=oldversion
Not developer issue:        https://bugs.php.net/fix.php?id=77099&r=support
Expected behavior:          https://bugs.php.net/fix.php?id=77099&r=notwrong
Not enough info:            https://bugs.php.net/fix.php?id=77099&r=notenoughinfo
Submitted twice:            https://bugs.php.net/fix.php?id=77099&r=submittedtwice
register_globals:           https://bugs.php.net/fix.php?id=77099&r=globals
PHP 4 support discontinued: https://bugs.php.net/fix.php?id=77099&r=php4
Daylight Savings:           https://bugs.php.net/fix.php?id=77099&r=dst
IIS Stability:              https://bugs.php.net/fix.php?id=77099&r=isapi
Install GNU Sed:            https://bugs.php.net/fix.php?id=77099&r=gnused
Floating point limitations: https://bugs.php.net/fix.php?id=77099&r=float
No Zend Extensions:         https://bugs.php.net/fix.php?id=77099&r=nozend
MySQL Configuration Error:  https://bugs.php.net/fix.php?id=77099&r=mysqlcfg



Thread (5 messages)

« previous php.bugs (#217803) next »