Package: file
Version: 4.17-4
Severity: normal
Tags: patch

"MPEG ADTS, layer I, v1" files are not recognized since
the test for the sample rate in byte at offset 2
suffers from a signedness problem (byte vs. ubyte).
Patch attached.

Thanks,
Johannes

-- System Information:
Debian Release: testing/unstable
  APT prefers unstable
  APT policy: (500, 'unstable'), (500, 'stable')
Architecture: i386 (i686)
Shell:  /bin/sh linked to /bin/bash
Kernel: Linux 2.6.18
Locale: LANG=C, [EMAIL PROTECTED] (charmap=ISO-8859-15)

Versions of packages file depends on:
ii  libc6                        2.3.6.ds1-5 GNU C Library: Shared libraries
ii  libmagic1                    4.17-4      File type determination library us

file recommends no packages.

-- no debconf information
--- magic.orig  2006-10-09 19:16:34.000000000 +0200
+++ magic       2006-10-09 19:16:41.000000000 +0200
@@ -581,8 +581,8 @@
 # modified by Joerg Jenderek
 # GRR the original test are too common for many DOS files, so test 32 <= kbits 
<= 448
 0      beshort&0xFFFE          0xFFFE  
->2     byte&0xF0       >0x0F           
->>2    byte&0xF0       <0xE1           MPEG ADTS, layer I, v1
+>2     ubyte&0xF0      >0x0F           
+>>2    ubyte&0xF0      <0xE1           MPEG ADTS, layer I, v1
 # rate
 >>>2      byte&0xF0       0x10           \b,  32 kBits
 >>>2      byte&0xF0       0x20           \b,  64 kBits

Reply via email to