Re: com php-src: Bug 61504 updated libmagic.patch: ext/fileinfo/libmagic.patch

From: Date: Sat, 05 May 2012 10:50:27 +0000
Subject: Re: com php-src: Bug 61504 updated libmagic.patch: ext/fileinfo/libmagic.patch
References: 1 2 3 4 5 6 7  Groups: php.cvs 
Request: Send a blank email to php-cvs+get-68956@lists.php.net to get a copy of this message
hi, On Sat, May 5, 2012 at 12:10 AM, Sean Coates <sean@seancoates.com> wrote: > In my opinion, it is too late to revert the new behaviour. Agreed. > I currently have this in my codebase: > >        if (version_compare(PHP_VERSION, '5.3.11') >= 0) { >                $magicfile = 'magic_php-gte-5_3_11.mgc'; >        } else { >                $magicfile = 'magic_php-lt-5-3-11.mgc'; >        } >        $magicpath = __DIR__ . "/../../../config/{$magicfile}"; >        $finfo = new finfo(FILEINFO_MIME_TYPE, $magicpath); > > Adding additional ifelse clauses for (e.g.) 5.3.13 and 5.4.2, etc. sounds like a nightmare. Right, but I do not understand why you do that in the 1st place. Is there anything in the bundled DB that does not fit your needs? Despite that this break was not intentional, using the bundled DB was and remains the recommended way. > The only way I could see this working is if the magic db parser somehow tries *both* the old > and new methods, and frankly, I don't think it's worth it at this point. > This really should never have gone into .11 in the first place. The damage is done; let's > not make it worse. Agreed too. Also please use the bug report to discuss issues, so we don't have many places to look at to get the backlog about this problem. Cheers, -- Pierre @pierrejoye | http://blog.thepimp.net | http://www.libgd.org

« previous php.cvs (#68956) next »