php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #39550 unlink() does not work if filename contains parenthesis.
Submitted: 2006-11-17 22:42 UTC Modified: 2006-11-20 15:43 UTC
From: andy at advancethermal dot com Assigned:
Status: Closed Package: Filesystem function related
PHP Version: 5.2.0 OS: Windows XP Pro & 2003 Server
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: andy at advancethermal dot com
New email:
PHP Version: OS:

 

 [2006-11-17 22:42 UTC] andy at advancethermal dot com
Description:
------------
unlink() does not delete a file if the filename contains parenthesis, while functions like file_get_contents() work fine.

Reproduce code:
---------------
$file = "c:/my file (4).txt";

unlink($file);

Expected result:
----------------
Expect file to be deleted.

Actual result:
--------------
File is not deleted.

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2006-11-20 10:00 UTC] tony2001@php.net
Do you see any error messages with error_reporting(E_ALL)? If yes, please post all of them here.
 [2006-11-20 15:43 UTC] andy at advancethermal dot com
Okay, I have no idea why, but both servers can delete files with parenthesis now. Please consider the issue as closed/bogus.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Dec 26 14:01:30 2024 UTC