php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #53703 Cannot upload patches with chars < chr(32)
Submitted: 2011-01-09 21:50 UTC Modified: 2014-12-31 08:24 UTC
Votes:3
Avg. Score:3.0 ± 0.0
Reproduced:0 of 0 (0.0%)
From: jthijssen at noxlogic dot nl Assigned:
Status: Open Package: Website problem
PHP Version: Irrelevant OS: NA
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 this is not your bug, you can add a comment by following this link.
If this is your bug, but you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: jthijssen at noxlogic dot nl
New email:
PHP Version: OS:

 

 [2011-01-09 21:50 UTC] jthijssen at noxlogic dot nl
Description:
------------
The "add-a-patch" system in the php.net bug tracker will check for mime-types after uploading a patch. When a file has some low ascii-characters, it will not be detected correctly as a plain text file. The upload will not success in that case.

There are some files in the php sources that have these low ascii characters present so patches on those files cannot be uploaded correctly.

Test script:
---------------
The files:
  ext/standard/tests/strings/strip_tags_variation5.phpt 
  ext/standard/tests/strings/strip_tags_variation8.phpt 
  ext/standard/tests/strings/strip_tags_variation9.phpt 
have some low ascii characters: ^K and ^L. Because of this, linux' "file" command detect those files "incorrectly":

jthijssen@debian-jth:~/php-src-5.3$ file ext/standard/tests/strings/strip_tags_variation5.phpt 
ext/standard/tests/strings/strip_tags_variation5.phpt: data
jthijssen@debian-jth:~/php-src-5.3$ file ext/standard/tests/strings/strip_tags_variation4.phpt 
ext/standard/tests/strings/strip_tags_variation4.phpt: ASCII C program text

Expected result:
----------------
The patch should be added to the bug

Actual result:
--------------
The bug database reports an incorrect filetype (detected: application/octet-stream)

Patches

test-script (last revision 2014-08-05 18:27 UTC by sobak@php.net)

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2014-08-05 18:26 UTC] sobak@php.net
-Assigned To: +Assigned To: sobak
 [2014-08-05 18:27 UTC] sobak@php.net
The following patch has been added/updated:

Patch Name: test-script
Revision:   1407263271
URL:        https://bugs.php.net/patch-display.php?bug=53703&patch=test-script&revision=1407263271
 [2014-12-31 08:24 UTC] sobak@php.net
-Assigned To: sobak +Assigned To:
 
PHP Copyright © 2001-2019 The PHP Group
All rights reserved.
Last updated: Tue Dec 10 11:01:23 2019 UTC