php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #10253 fopen returns pointer to empty file
Submitted: 2001-04-09 17:16 UTC Modified: 2001-04-09 19:53 UTC
From: mlane at nucleus dot com Assigned:
Status: Closed Package: Filesystem function related
PHP Version: 4.0.3pl1 OS: Slackware Current
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: mlane at nucleus dot com
New email:
PHP Version: OS:

 

 [2001-04-09 17:16 UTC] mlane at nucleus dot com
<?
$fp=fopen ("/usr/local/apache/htdocs/sales.nationalonline.ca/test/test.file", "r+");
print $fp;
if (!$fp) print "error";
else $rt=filesize($fp);
print $rt;
print "blue:";
?>
 Resource id #1blue:

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2001-04-09 19:53 UTC] sniper@php.net
1. Read the manual page for filesize() at http://www.php.net/filesize
(hint: It wants a filename as parameter)

2. If this was just buggy example script and you can 
reproduce whatever happens with latest CVS snapshot from http://snaps.php.net/ then reopen this bug report.

--Jani

 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Mon May 06 14:01:33 2024 UTC