php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #19750 php_hostconnect: connect failed
Submitted: 2002-10-04 04:19 UTC Modified: 2002-10-05 06:33 UTC
From: indy at civ dot zcu dot cz Assigned:
Status: Closed Package: Network related
PHP Version: 4.2.3 OS: Linux
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: indy at civ dot zcu dot cz
New email:
PHP Version: OS:

 

 [2002-10-04 04:19 UTC] indy at civ dot zcu dot cz
Hello, 
previous reported bug with function file is still in PHP 4.2.3.

I tried this simple script:
<?
if ($fr = fopen("ftp://ftp.zcu.cz/mirrors/simtelnet/gnu/gnuish/00-index", "r")) {   
               $data = fread($fr, 20000000);
               printf("%s", $data);               
               fclose($fr);
            }
?>

the file on FTP exists and I always get: 
<b>Warning</b>:  php_hostconnect: connect failed in ...
<b>Warning</b>:  fopen("ftp://ftp.zcu.cz/mirrors/simtelnet/gnu/gnuish/00-index", "r") - Bad file descriptor in ...
--
Now I tried the latest snapshot (php4-200210040000) and the script do nothing -- just waiting to max_execution_time :-( 

My PHP config line: './configure' '--enable-versioning' '--with-mysql=/usr/local/mysql' '--enable-track-vars' '--with-gd' '--with-xml' '--disable-debug' '--enable-sysvshm' '--enable-sysvsem' '--with-jpeg-dir' '--with-tiff-dir' '--enable-trans-sid' '--with-config-file-path=/usr/local/apache/conf' '--with-zlib-dir' '--enable-sockets' '--with-pgsql=/usr/local/postgresql' '--enable-gd-native-ttf' '--with-png-dir'

OS: Linux, kernel 2.4.17 #1

Petr Grolmus

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2002-10-04 05:17 UTC] mfischer@php.net
This is what I get with current CVS:

$ php 19750.php

Warning: fopen() [http://www.php.net/function.fopen]: php_hostconnect: connect failed in 19750.php on line 3
19750.php(3) : Warning - fopen() [http://www.php.net/function.fopen]: php_hostconnect: connect failed

Warning: fopen(ftp://ftp.zcu.cz/mirrors/simtelnet/gnu/gnuish/00-index) [http://www.php.net/function.fopen]: failed to create stream: FTP server reports 229 Entering Extended Passive Mode (|||4294949117|).
 in 19750.php on line 3
19750.php(3) : Warning - fopen(ftp://ftp.zcu.cz/mirrors/simtelnet/gnu/gnuish/00-index) [http://www.php.net/function.fopen]: failed to create stream: FTP server reports 229 Entering Extended Passive Mode (|||4294949117|).

Wez ?
 [2002-10-05 06:33 UTC] mfischer@php.net
This bug has been fixed in CVS.

In case this was a PHP problem, snapshots of the sources are packaged
every three hours; this change will be in the next snapshot. You can
grab the snapshot at http://snaps.php.net/.
 
In case this was a documentation problem, the fix will show up soon at
http://www.php.net/manual/.

In case this was a PHP.net website problem, the change will show
up on the PHP.net site and on the mirror sites in short time.
 
Thank you for the report, and for helping us make PHP better.

Send kossu und pizzas to Stefna.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Apr 19 05:01:29 2024 UTC