php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Doc Bug #48522 file_put_contents() flags FILE_APPEND and LOCK_EX are mutually exclusive
Submitted: 2009-06-10 18:05 UTC Modified: 2009-06-24 10:53 UTC
From: gwynne@php.net Assigned:
Status: Closed Package: Documentation problem
PHP Version: Irrelevant OS: *
Private report: No CVE-ID: None
 [2009-06-10 18:05 UTC] gwynne@php.net
Description:
------------
Checking out the source for PHP 5.3, one sees:

php-5.3/ext/standard/file.c:614
	if (flags & PHP_FILE_APPEND) {
		mode[0] = 'a';
	} else if (flags & LOCK_EX) {

Obviously FILE_APPEND and LOCK_EX are mutually exclusive. This is not documented!

Reproduce code:
---------------
---
From manual page: function.file-put-contents
---


Expected result:
----------------
... It's a documentation bug.

Actual result:
--------------
Once again I say... it's a DOCS bug!

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2009-06-24 10:53 UTC] rasmus@php.net
This bug has been fixed in the documentation's XML sources. Since the
online and downloadable versions of the documentation need some time
to get updated, we would like to ask you to be a bit patient.

Thank you for the report, and for helping us make our documentation better.


 [2010-09-08 02:17 UTC] cataphract@php.net
Automatic comment from SVN on behalf of cataphract
Revision: http://svn.php.net/viewvc/?view=revision&revision=303153
Log: - Reversing changes from revisions 288122 and 282711, which addressed bug #49329 and bug #48522 (bogus bugs).
- Closes bug #52767.
 [2020-02-07 06:10 UTC] phpdocbot@php.net
Automatic comment on behalf of rasmus
Revision: http://git.php.net/?p=doc/en.git;a=commit;h=2f23be37bfb4b4367dab2fda79203463812d7b55
Log: Fix bug #48522 to make Gwynne happy.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri May 17 03:01:32 2024 UTC