]> git.lyx.org Git - features.git/commitdiff
correct magic for gzip and compress
authorLars Gullik Bjønnes <larsbj@gullik.org>
Mon, 28 Jul 2003 12:47:20 +0000 (12:47 +0000)
committerLars Gullik Bjønnes <larsbj@gullik.org>
Mon, 28 Jul 2003 12:47:20 +0000 (12:47 +0000)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@7412 a592a061-630c-0410-9148-cb99ea01b6c8

src/support/ChangeLog
src/support/filetools.C

index bbd9ad4366e2a4c17998f8ee9cf2171293fe9ddf..f8f3627e328ed2618c0f76c41d6daf48e085b90e 100644 (file)
@@ -1,6 +1,11 @@
 2003-07-28  Lars Gullik Bjønnes  <larsbj@gullik.net>
 
-       * gzstream.h: new file
+       * filetools.C (getExtFromContents): correct magic for gzip and
+       compress.
+
+       * path_defines.[Ch]: move lyx_localedir out of anon namespace
+
+       * gzstream.h: new fileq
 
        * gzstream.C: new file
 
index b7f4eea293e0cdd9acb96967ea7cf6518222e861..99d2420407acdd9c1387e8909f8b3f4410b45572 100644 (file)
@@ -955,9 +955,9 @@ string const GetExtension(string const & name)
 //      ...static char *...
 // XWD \000\000\000\151        (0x00006900) decimal 105
 //
-// GZIP        \037\213\010\010...     http://www.ietf.org/rfc/rfc1952.txt
+// GZIP        \037\213        http://www.ietf.org/rfc/rfc1952.txt
 // ZIP PK...                   http://www.halyava.ru/document/ind_arch.htm
-// Z   \037\177                UNIX compress
+// Z   \037\235                UNIX compress
 
 /// return the "extension" which belongs to the contents.
 /// for no knowing contents return the extension. Without
@@ -975,13 +975,13 @@ string const getExtFromContents(string const & filename)
                return string();
 
        // gnuzip
-       string const gzipStamp = "\037\213\010\010";
+       string const gzipStamp = "\037\213";
 
        // PKZIP
        string const zipStamp = "PK";
 
        // compress
-       string const compressStamp = "\037\177";
+       string const compressStamp = "\037\235";
 
        // Maximum strings to read
        int const max_count = 50;