php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #22579 fopen() number in URL = Bad file descriptor
Submitted: 2003-03-06 20:50 UTC Modified: 2003-03-12 17:06 UTC
Votes:5
Avg. Score:4.8 ± 0.4
Reproduced:4 of 4 (100.0%)
Same Version:3 (75.0%)
Same OS:3 (75.0%)
From: ottawasixtyseven at hotmail dot com Assigned:
Status: Closed Package: Filesystem function related
PHP Version: 4.3.0 OS: ALL
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: ottawasixtyseven at hotmail dot com
New email:
PHP Version: OS:

 

 [2003-03-06 20:50 UTC] ottawasixtyseven at hotmail dot com
This bug has been reported a few times but keeps getting closed. It is still a problem in PHP 4.3.0 

Also see closed bug http://bugs.php.net/bug.php?id=9862

There is a serious problem with fopen when there are numbers in the URL: http://www.xxxxxxx.com:8080/some.php?Origin=a&DocNum=1

Result:

Warning: fopen() [function.fopen]: php_hostconnect: connect failed in C:\phpfiles\some.php on line 150

Warning: fopen(http://www.xxxxxxx.com:8080/some.php?Origin=a&DocNum=1) [function.fopen]: failed to create stream: Bad file descriptor in C:\phpfiles\some.php on line 150


Remove the port number in the URL and it works fine: http://www.xxxxxxx.com/some.php?Origin=a&DocNum=1

This seems to be a random bug that occurs on some machines and not others. We can reproduce it 100% of the time if someone wants to check on our server.

Please don't just test this on one machine and report back that it works for you. There is something wrong here and we really need to get to the bottom of it. It's not a redirection problem.

Thanks. Keep up the great work!

Ottawa

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2003-03-11 12:49 UTC] sniper@php.net
I can't get our application running on the latest snapshot. I can run
phpinfo() but when I try to $DB  = odbc_connect I get errors. More
specifically, when I first echo $DB I get "Resource id #3" when echo it
again I get
"FATAL: erealloc(): Unable to allocate 1331643757 bytes"

I have tried installing the latest snapshot on three separate servers.
Two that were already running PHP 4.3 and one clean server.

I'm not able to test if the latest snapshot has fixed the fopen() bug.
Any ideas why my odbc_connect is failing?

--------

What does odbc have to do with fopen() problem?
Test with separate script which doesn't have odbc stuff in it..

And the odbc problem, open a new report about that one.

 [2003-03-11 22:01 UTC] ottawasixtyseven at hotmail dot com
OK. Just wanted to let you know we're trying to test the latest snapshot to see if it fixes the fopen problem. I guess we'll have to weed out the odbc parts.
 [2003-03-12 16:58 UTC] ottawasixtyseven at hotmail dot com
Fixed in latest snapshot. Thank you.

Ottawa
 [2003-03-12 17:06 UTC] pollita@php.net
Fixed -> Closed.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sat May 18 11:01:34 2024 UTC