php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #80102 stream_socket_client can't connect
Submitted: 2020-09-14 11:48 UTC Modified: 2020-09-14 12:55 UTC
From: contact at laurent-aubertin dot com Assigned: cmb (profile)
Status: Duplicate Package: Sockets related
PHP Version: 7.4.10 OS: ubuntu
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.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: contact at laurent-aubertin dot com
New email:
PHP Version: OS:

 

 [2020-09-14 11:48 UTC] contact at laurent-aubertin dot com
Description:
------------
error : Warning: stream_socket_client(): unable to connect to tcp://127.0.0.1:7687 (Failed to parse address "null")

this connection work fine in PHP 7.4.9

No change in my code, just upgrade from 7.4.9 to 7.4.10




Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2020-09-14 11:50 UTC] sjon@php.net
-Status: Open +Status: Feedback
 [2020-09-14 11:50 UTC] sjon@php.net
Thank you for this bug report. To properly diagnose the problem, we
need a short but complete example script to be able to reproduce
this bug ourselves.

A proper reproducing script starts with <?php and ends with ?>,
is max. 10-20 lines long and does not require any external
resources such as databases, etc. If the script requires a
database to demonstrate the issue, please make sure it creates
all necessary tables, stored procedures etc.

Please avoid embedding huge scripts into the report.

> var_dump(stream_socket_client('tcp://127.0.0.1:7687'));

this works fine for me - does this single line fail for you as well?
 [2020-09-14 12:28 UTC] contact at laurent-aubertin dot com
The error comes from a bad value in the context parameter.
Migration to PHP 7.4.10 created this bad value.
The problem is not in stream_socket_client but elsewhere. I continue to search for the source of the problem.
Sorry for this false alert on this feature. The ticket can be closed.
 [2020-09-14 12:55 UTC] cmb@php.net
-Status: Feedback +Status: Duplicate -Assigned To: +Assigned To: cmb
 [2020-09-14 12:55 UTC] cmb@php.net
That's a duplicate of bug #80067, which has already been fixed; the fix will be contained in PHP 7.4.11.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Wed Apr 24 16:01:31 2024 UTC