php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #69135 finfo_file memory leak
Submitted: 2015-02-27 10:12 UTC Modified: 2015-03-02 13:26 UTC
Votes:1
Avg. Score:3.0 ± 0.0
Reproduced:1 of 1 (100.0%)
Same Version:1 (100.0%)
Same OS:1 (100.0%)
From: zeke at cs-cart dot com Assigned: ab (profile)
Status: Duplicate Package: Filesystem function related
PHP Version: 5.6.6 OS: ubuntu
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: zeke at cs-cart dot com
New email:
PHP Version: OS:

 

 [2015-02-27 10:12 UTC] zeke at cs-cart dot com
Description:
------------
finfo_file fails with "allowed memory size of nnn bytes exhausted" on some file types. In my case it's csv, which you can download here
https://www.dropbox.com/s/oivtic8g4r9tb20/products_general_11052014.csv?dl=0

The problem reproduces approximately since 5.5.14 to the latest 5.6.6.

Test script:
---------------
<?php

$f = finfo_open(FILEINFO_MIME);
finfo_file($f, './products_general_11052014.csv');

echo('ok');

Expected result:
----------------
"ok" should be output

Actual result:
--------------
Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 4294947908 bytes) in test.php on line 4


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2015-02-27 15:15 UTC] laruence@php.net
-Assigned To: +Assigned To: ab
 [2015-03-02 13:26 UTC] ab@php.net
-Status: Assigned +Status: Duplicate
 [2015-03-02 13:26 UTC] ab@php.net
see bug #68819
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Apr 26 13:01:28 2024 UTC