Bug #80583 [Com]: cli readline causes crash
| From: | summerdevon40 at gmail dot com | Date: | Sat, 09 Jan 2021 09:46:59 +0000 |
| Subject: | Bug #80583 [Com]: cli readline causes crash | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-231458@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=80583&edit=1
ID: 80583
Comment by: summerdevon40 at gmail dot com
Reported by: jan dot hana at atlas dot cz
Summary: cli readline causes crash
Status: Verified
Type: Bug
Package: *Unicode Issues
Operating System: Ubuntu 20.04
PHP Version: 8.0.0
Block user comment: N
Private report: N
New Comment:
Thanks for the update and quick reply. I'll be sure to keep an eye on this thread. Looking
for the same issue. Bumped into your thread. Thanks for creating it. Looking forward for solution.
https://www.mcdvoice.onl/
Previous Comments:
------------------------------------------------------------------------
[2021-01-04 14:05:06] nikic@php.net
This works on 7.4 and 8.0:
var_dump(setlocale(LC_ALL, 'en_US.UTF-8'));
readline('doména ÄÅ¡ÄÅžýáÃé');
This crashes on 7.4 and 8.0:
var_dump(setlocale(LC_ALL, 'C'));
readline('doména ÄÅ¡ÄÅžýáÃé');
Locale-dependent crashes in libedit, this is horrible.
------------------------------------------------------------------------
[2021-01-04 13:53:00] jan dot hana at atlas dot cz
Description:
------------
When using the Czech diacritics in readline parametter, whole application crashes.
It works in PHP 7.4.
Test script:
---------------
<?php
readline('doména ÄÅ¡ÄÅžýáÃé');
Actual result:
--------------
NeoprávnÄný pÅÃstup do pamÄti (SIGSEGV) (core dumped [obraz pamÄti uložen])
Translated to EN: Unauthorized Memory Access (SIGSEGV) (core dumped)
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=80583&edit=1