lzip-bug
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Lzip-bug] lzip support in file(1)/magic(5)


From: Jan Engelhardt
Subject: [Lzip-bug] lzip support in file(1)/magic(5)
Date: Thu, 27 Nov 2008 21:21:42 +0100 (CET)
User-agent: Alpine 1.10 (LNX 962 2008-03-14)

Hi,


wanting to let you know that the following patch has been submitted to 
the file(1) maintainer.

>From it, you can grab the lzip-specific mgc bits (just the four lines to 
Magdir/compress) and put it as a standalone file into the lzip software 
distribution if you like.


thanks,
Jan


---------- Forwarded message ----------
Date: Wed, 26 Nov 2008 19:59:38 +0100 (CET)
From: Jan Engelhardt
To: christos
Subject: LZIP support


Add LZIP support to magic(5).

Signed-off-by: Jan Engelhardt <address@hidden>

---
 magic/Magdir/compress |    7 +++++++
 src/compress.c        |    1 +
 2 files changed, 8 insertions(+)

Index: file-4.26/magic/Magdir/compress
===================================================================
--- file-4.26.orig/magic/Magdir/compress
+++ file-4.26/magic/Magdir/compress
@@ -202,3 +202,10 @@
 >4     byte            x               - version %d
 >5     byte            x               \b.%d
 >6     belong          x               (%d bytes)
+
+
+# lzip, http://freshmeat.net/p/lzip/
+0      string          LZIP            lzip compressed data
+!:mime application/x-lzip
+>4     byte            x               \b, version %d
+>5     byte            x               \b, dictionary size 2^%d
Index: file-4.26/src/compress.c
===================================================================
--- file-4.26.orig/src/compress.c
+++ file-4.26/src/compress.c
@@ -65,6 +65,7 @@ private const struct {
        const char *argv[3];
        int silent;
 } compr[] = {
+       { "LZIP",     4, { "lzip", "-cdq", NULL }, 1 },
        { "\037\235", 2, { "gzip", "-cdq", NULL }, 1 },         /* compressed */
        /* Uncompress can get stuck; so use gzip first if we have it
         * Idea from Damien Clark, thanks! */





reply via email to

[Prev in Thread] Current Thread [Next in Thread]