Doc #69773 [Opn->Nab]: Fileinfo is unable to load internal MIME database
| From: | ab@php.net | Date: | Thu, 24 Nov 2016 14:54:42 +0000 |
| Subject: | Doc #69773 [Opn->Nab]: Fileinfo is unable to load internal MIME database | ||
| References: | 1 | Groups: | php.doc.bugs |
| Request: | Send a blank email to doc-bugs+get-14140@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=69773&edit=1
ID: 69773
Updated by: ab@php.net
Reported by: letynsoft at gmail dot com
Summary: Fileinfo is unable to load internal MIME database
-Status: Open
+Status: Not a bug
Type: Documentation Problem
Package: *General Issues
Operating System: Ubuntu 15.04 (upgraded)
PHP Version: 5.6.9
Block user comment: N
Private report: N
New Comment:
I don't reproduce this (anymore), also in higher versions. Feel free to reopen, if you've
more details.
Thanks.
Previous Comments:
------------------------------------------------------------------------
[2015-06-08 16:17:57] letynsoft at gmail dot com
Description:
------------
When i do not pass the second parameter to the new finfo() constructor (or pass NULL), it is
supposed to load it's internal database but it doesn't load that. it just sais:
Warning: finfo::file(): Failed identify data 0:no magic files loaded.
It does the same, if i pass the /etc/magic.mime, but that file appears to be empty.
PS: i didn't find the PHP version in the dropdown, my PHP Version 5.6.4-4ubuntu6
PS2: I also didn't find the Fileinfo package in the 'Package Affected' dropdown (it
is in the Advanced search, but not in the Report a Bug form)
Test script:
---------------
$finfo = new finfo(FILEINFO_MIME);
$mime = $finfo->file('/path/to/file');
Expected result:
----------------
it should produce the file mime type
Actual result:
--------------
Warning is thrown
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=69773&edit=1