Bug #79923 [PATCH]: socket_set_option_bindtodevice.phpt fails on PHP 8
| From: | santi@mola.io | Date: | Sun, 02 Aug 2020 13:57:01 +0000 |
| Subject: | Bug #79923 [PATCH]: socket_set_option_bindtodevice.phpt fails on PHP 8 | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-228375@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=79923&edit=1
ID: 79923
Patch added by: santi@mola.io
Reported by: santi at mola dot io
Summary: socket_set_option_bindtodevice.phpt fails on PHP 8
Status: Open
Type: Bug
Package: Sockets related
Operating System: Linux
PHP Version: 8.0.0alpha3
Block user comment: N
Private report: N
New Comment:
The following pull request has been associated:
Patch Name: Fix #79923: fix socket_set_option_bindtodevice test
On GitHub: https://github.com/php/php-src/pull/5924
Patch: https://github.com/php/php-src/pull/5924.patch
Previous Comments:
------------------------------------------------------------------------
[2020-08-02 13:53:42] santi at mola dot io
Updated summary, introduced a dupe one with autocompletion.
------------------------------------------------------------------------
[2020-08-02 13:49:39] santi at mola dot io
Description:
------------
A change in error text (initial capitalization) for the socket extensions makes a test fail in PHP
8.
The issue was introduced here: https://github.com/php/php-src/commit/7ff8eaa5451275a5ce97b29381fc08412e6489d7
The test is ext/sockets/tests/socket_set_option_bindtodevice.phpt
Test script:
---------------
#!/bin/sh
# Run on the ubuntu:20.04 docker image:
# docker run --rm --privileged -v $(pwd):/work -w /work ubuntu:20.04 /work/repro.sh
set -ex
DEBIAN_FRONTEND=nointeractive
apt-get update
apt-get install -y --no-install-recommends autoconf bison \
build-essential locales openssl re2c pkg-config
./buildconf -f
./configure --disable-all --disable-phpdbg --enable-posix --enable-sockets --without-libxml
--without-sqlite3 --without-pdo-sqlite
make -j $(nproc)
make test TESTS=ext/sockets/tests/socket_set_option_bindtodevice.phpt
Actual result:
--------------
---- EXPECTED OUTPUT
bool(true)
Warning: socket_set_option(): unable to set socket option [19]: No such device in %s on line %d
bool(false)
---- ACTUAL OUTPUT
bool(true)
Warning: socket_set_option(): Unable to set socket option [19]: No such device in
/work/ext/sockets/tests/socket_set_option_bindtodevice.php on line 10
bool(false)
---- FAILED
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=79923&edit=1