Commit Graph

32 Commits

Author SHA1 Message Date
Scott MacVicar
7a29c8f386 MFH Update fileinfo to libmagic 5.00 and remove dependency on dirent.h on Windows 2009-03-15 23:04:19 +00:00
Scott MacVicar
372256b002 MFH Remove all of the stuff we have in here for pre PHP 5.2 support and memset the fileinfo struct. 2008-12-22 16:45:07 +00:00
Felipe Pena
fc2fb50d09 - MFH: Added 'static' into ZEND_BEGIN_ARG_INFO_EX macro 2008-11-17 11:28:01 +00:00
Felipe Pena
7a37fa2d6b - Revert ZEND_BEGIN_ARG_INFO change 2008-11-02 21:19:39 +00:00
Felipe Pena
df10005563 - MFH: Added 'static' into ZEND_BEGIN_ARG_INFO_EX macro 2008-10-24 14:35:40 +00:00
Antony Dovgal
02022c766c MFH: fix compile warning 2008-09-16 09:48:17 +00:00
Scott MacVicar
3940782c25 MFH: Fix memory leak in a few cases 2008-09-16 09:46:24 +00:00
Scott MacVicar
b845244370 Missed variable declaration. 2008-09-15 22:16:25 +00:00
Scott MacVicar
db907e5bc3 Fixed bug #46086 (Segfault when accessing fileinfo class property) 2008-09-15 22:13:25 +00:00
Antony Dovgal
8209f891a4 MFH 2008-09-13 21:32:21 +00:00
Pierre Joye
c8a0c3b0f5 - don't close caller streams in libmagic (prevent leak and zombie stream)
- string returned by magic_* are freed on magic_close, duplicate before
  calling magic_close (set return value)
- if stat failed, don't try to call magic_* (when FILEINFO_MODE_FILE)
2008-09-02 10:15:54 +00:00
Felipe Pena
d13b704d25 - Fixed mime_content_type() behavior when a string is given
- Fixed check for "empty file name"
- MFH: New test
2008-09-01 23:44:00 +00:00
Pierre Joye
99041160df - use php's stream in libmagic
- remove duplicate code (like mime_content_type() compatibility function
  now use the same base as finfo_file())
- make it portable (works now on windows too, belongs other OSes)

- ([20:28]  <lsmith> Pierre: ok please commit)
2008-09-01 18:56:06 +00:00
Antony Dovgal
fa978e8595 MFH: check for \0 to be consistent with other functions 2008-08-29 13:48:38 +00:00
Derick Rethans
057b2401bf - Disable COMPRESS support for now, as it requires forking.
# @DOC [DOC] "DOC"
2008-08-29 13:39:01 +00:00
Derick Rethans
4ca7e129a7 - MFH: Adding back in mime_content_type(). 2008-08-29 13:29:42 +00:00
Antony Dovgal
3bd40d9000 fix file check and avoid segfault 2008-08-27 07:40:44 +00:00
Felipe Pena
7208556ca4 - MFH: Fixed check for empty file name 2008-08-27 01:04:23 +00:00
Felipe Pena
d8c43bde79 - MFH: Improved fix 2008-08-26 16:22:27 +00:00
Felipe Pena
727990f432 - MFH: Added check for empty file name 2008-08-26 15:06:28 +00:00
Felipe Pena
8085094da8 MFH:
- Added arginfo
- Fixed:
  . proto: finfo_buffer
  . parameter type in _php_finfo_get_type()
2008-07-25 15:23:10 +00:00
Jani Taskinen
ccc012d3f6 MFH: enable fileinfo by default 2008-07-25 09:16:22 +00:00
SVN Migration
14ce4a1d0a This commit was manufactured by cvs2svn to create branch 'PHP_5_3'. 2008-07-25 02:44:58 +00:00
SVN Migration
4571221d8e This commit was manufactured by cvs2svn to create branch 'PHP_5_1'. 2005-08-08 23:59:05 +00:00
Antony Dovgal
5e8cd3a2da fix segfault when failed to open magic file 2005-01-31 15:01:47 +00:00
Ilia Alshanetsky
25fd4c3bc2 Fixed ZTS build 2005-01-24 23:53:00 +00:00
Derick Rethans
f7afbb9370 - Fixed type which prevented this extension from being loaded as shared
extension.
2004-05-08 17:34:07 +00:00
Ilia Alshanetsky
d641ba3eae More C++ comments. 2004-04-21 23:16:34 +00:00
Ilia Alshanetsky
1b80b33b87 C++ comments are ungood ;). 2004-04-21 23:06:26 +00:00
Hartmut Holzgraefe
375b5df63d libmagic will only consume up to HOWMANY (hardcoded to 65536) bytes
from a file, so lets save bandwith and memory by limiting us to this
2004-04-21 22:49:35 +00:00
Ilia Alshanetsky
5a38078385 Fixes for PHP 4.3.X. 2004-02-13 01:19:57 +00:00
Ilia Alshanetsky
eb06e0c425 Initial commit of the fileinfo extension. 2004-02-13 01:06:06 +00:00