Hello community,
here is the log from the commit of package file for openSUSE:Factory checked in at 2015-07-21 13:25:14
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/file (Old)
and /work/SRC/openSUSE:Factory/.file.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "file"
Changes:
--------
--- /work/SRC/openSUSE:Factory/file/file.changes 2015-07-05 17:49:55.000000000 +0200
+++ /work/SRC/openSUSE:Factory/.file.new/file.changes 2015-07-21 13:25:25.000000000 +0200
@@ -1,0 +2,8 @@
+Tue Jul 14 11:48:47 UTC 2015 - werner@suse.de
+
+- Update to file version 5.24
+ * redo long option encoding to fix off-by-one in 5.23
+- Adapt and rename patch
+ file-5.12-nitpick.dif becomes file-5.24-nitpick.dif
+
+-------------------------------------------------------------------
--- /work/SRC/openSUSE:Factory/file/python-magic.changes 2015-07-05 17:49:55.000000000 +0200
+++ /work/SRC/openSUSE:Factory/.file.new/python-magic.changes 2015-07-21 13:25:25.000000000 +0200
@@ -1,0 +2,5 @@
+Tue Jul 14 14:16:29 UTC 2015 - werner@suse.de
+
+- adapt version in specfile to 5.24
+
+-------------------------------------------------------------------
Old:
----
file-5.12-nitpick.dif
file-5.23.tar.gz
New:
----
file-5.24-nitpick.dif
file-5.24.tar.gz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ file.spec ++++++
--- /var/tmp/diff_new_pack.lXk2lK/_old 2015-07-21 13:25:26.000000000 +0200
+++ /var/tmp/diff_new_pack.lXk2lK/_new 2015-07-21 13:25:26.000000000 +0200
@@ -1,7 +1,7 @@
#
# spec file for package file
#
-# Copyright (c) 2015 SUSE LINUX Products GmbH, Nuernberg, Germany.
+# Copyright (c) 2015 SUSE LINUX GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@@ -30,7 +30,7 @@
%endif
#
# Set Version also in python-magic.spec
-Version: 5.23
+Version: 5.24
Release: 0
Summary: A Tool to Determine File Types
License: BSD-2-Clause
@@ -59,7 +59,7 @@
Patch32: file-5.19-clicfs.dif
Patch33: file-5.16-ocloexec.patch
Patch34: file-5.23-endian.patch
-Patch35: file-5.12-nitpick.dif
+Patch35: file-5.24-nitpick.dif
Patch36: file-5.15-clear-invalid.patch
Patch37: file-secure_getenv.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-build
++++++ python-magic.spec ++++++
--- /var/tmp/diff_new_pack.lXk2lK/_old 2015-07-21 13:25:26.000000000 +0200
+++ /var/tmp/diff_new_pack.lXk2lK/_new 2015-07-21 13:25:26.000000000 +0200
@@ -1,7 +1,7 @@
#
# spec file for package python-magic
#
-# Copyright (c) 2015 SUSE LINUX Products GmbH, Nuernberg, Germany.
+# Copyright (c) 2015 SUSE LINUX GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@@ -23,7 +23,7 @@
BuildRequires: python-devel
BuildRequires: zlib-devel
Url: http://www.darwinsys.com/file/
-Version: 5.23
+Version: 5.24
Release: 0
Summary: Python module to use libmagic
License: BSD-3-Clause and BSD-4-Clause
++++++ file-5.12-nitpick.dif -> file-5.24-nitpick.dif ++++++
--- /work/SRC/openSUSE:Factory/file/file-5.12-nitpick.dif 2013-10-02 08:48:17.000000000 +0200
+++ /work/SRC/openSUSE:Factory/.file.new/file-5.24-nitpick.dif 2015-07-21 13:25:24.000000000 +0200
@@ -1,19 +1,24 @@
+---
+ src/file.c | 8 ++++++++
+ src/file_opts.h | 4 ++--
+ 2 files changed, 10 insertions(+), 2 deletions(-)
+
--- src/file.c
-+++ src/file.c 2013-09-30 00:00:00.000000000 +0000
-@@ -94,10 +94,12 @@ private const char *separator = ":"; /*
- private const struct option long_options[] = {
++++ src/file.c 2015-07-14 11:45:26.449520700 +0000
+@@ -96,10 +96,12 @@ private const struct option long_options
+ #define OPT_MIME_ENCODING 5
#define OPT(shortname, longname, opt, doc) \
{longname, opt, NULL, shortname},
-+#define OPT_POSIX OPT
- #define OPT_LONGONLY(longname, opt, doc) \
- {longname, opt, NULL, 0},
++#define OPT_POSIX OPT
+ #define OPT_LONGONLY(longname, opt, doc, id) \
+ {longname, opt, NULL, id},
#include "file_opts.h"
#undef OPT
+#undef OPT_POSIX
#undef OPT_LONGONLY
{0, 0, NULL, 0}
};
-@@ -525,6 +527,7 @@ docprint(const char *opts)
+@@ -595,6 +597,7 @@ docprint(const char *opts)
private void
help(void)
{
@@ -21,7 +26,7 @@
(void)fputs(
"Usage: file [OPTION...] [FILE...]\n"
"Determine type of FILEs.\n"
-@@ -532,11 +535,16 @@ help(void)
+@@ -602,11 +605,16 @@ help(void)
#define OPT(shortname, longname, opt, doc) \
fprintf(stdout, " -%c, --" longname, shortname), \
docprint(doc);
@@ -29,7 +34,7 @@
+ fprintf(stdout, " -%c, --" longname "%s", shortname, \
+ (shortname == 'L') ? (posix ? " (default)" : "") : (posix ? "" : " (default)")), \
+ docprint(doc);
- #define OPT_LONGONLY(longname, opt, doc) \
+ #define OPT_LONGONLY(longname, opt, doc, id) \
fprintf(stdout, " --" longname), \
docprint(doc);
#include "file_opts.h"
@@ -40,7 +45,7 @@
exit(0);
--- src/file_opts.h
+++ src/file_opts.h 2013-09-30 13:44:17.000000000 +0000
-@@ -34,8 +34,8 @@ OPT_LONGONLY("mime-encoding", 0, "
+@@ -36,8 +36,8 @@ OPT_LONGONLY("mime-encoding", 0, "
OPT('k', "keep-going", 0, " don't stop at the first match\n")
OPT('l', "list", 0, " list magic strength\n")
#ifdef S_IFLNK
++++++ file-5.23.tar.gz -> file-5.24.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/file-5.23/ChangeLog new/file-5.24/ChangeLog
--- old/file-5.23/ChangeLog 2015-06-10 19:48:07.000000000 +0200
+++ new/file-5.24/ChangeLog 2015-07-09 16:38:06.000000000 +0200
@@ -1,3 +1,10 @@
+2015-07-09 10:35 Christos Zoulas
16 leshort 0 no file type, !:mime application/octet-stream @@ -55,47 +81,26 @@ 18 leshort 8 # only for 32-bit
4 byte 1 ->>>36 lelong&0xf0000000 0x00000000 MIPS-I ->>>36 lelong&0xf0000000 0x10000000 MIPS-II ->>>36 lelong&0xf0000000 0x20000000 MIPS-III ->>>36 lelong&0xf0000000 0x30000000 MIPS-IV ->>>36 lelong&0xf0000000 0x40000000 MIPS-V ->>>36 lelong&0xf0000000 0x50000000 MIPS32 ->>>36 lelong&0xf0000000 0x60000000 MIPS64 ->>>36 lelong&0xf0000000 0x70000000 MIPS32 rel2 ->>>36 lelong&0xf0000000 0x80000000 MIPS64 rel2 +>>>36 use elf-mips # only for 64-bit 4 byte 2 ->>>48 lelong&0xf0000000 0x00000000 MIPS-I ->>>48 lelong&0xf0000000 0x10000000 MIPS-II ->>>48 lelong&0xf0000000 0x20000000 MIPS-III ->>>48 lelong&0xf0000000 0x30000000 MIPS-IV ->>>48 lelong&0xf0000000 0x40000000 MIPS-V ->>>48 lelong&0xf0000000 0x50000000 MIPS32 ->>>48 lelong&0xf0000000 0x60000000 MIPS64 ->>>48 lelong&0xf0000000 0x70000000 MIPS32 rel2 ->>>48 lelong&0xf0000000 0x80000000 MIPS64 rel2 +>>>48 use elf-mips 18 leshort 9 Amdahl, 18 leshort 10 MIPS (deprecated), 18 leshort 11 RS6000, 18 leshort 15 PA-RISC, # only for 32-bit 4 byte 1 ->>>38 leshort 0x0214 2.0 ->>>36 leshort &0x0008 (LP64) +>>>36 use elf-pa-risc # only for 64-bit 4 byte 2 ->>>50 leshort 0x0214 2.0 ->>>48 leshort &0x0008 (LP64) +>>>48 use elf-pa-risc 18 leshort 16 nCUBE, 18 leshort 17 Fujitsu VPP500, 18 leshort 18 SPARC32PLUS, # only for 32-bit 4 byte 1 ->>>36 lelong&0xffff00 0x000100 V8+ Required, ->>>36 lelong&0xffff00 0x000200 Sun UltraSPARC1 Extensions Required, ->>>36 lelong&0xffff00 0x000400 HaL R1 Extensions Required, ->>>36 lelong&0xffff00 0x000800 Sun UltraSPARC3 Extensions Required, +>>>36 use elf-sparc 18 leshort 19 Intel 80960, 18 leshort 20 PowerPC or cisco 4500, 18 leshort 21 64-bit PowerPC or cisco 7500, @@ -117,12 +122,7 @@ 18 leshort 42 Renesas SH, 18 leshort 43 SPARC V9, 4 byte 2 ->>>48 lelong&0xffff00 0x000200 Sun UltraSPARC1 Extensions Required, ->>>48 lelong&0xffff00 0x000400 HaL R1 Extensions Required, ->>>48 lelong&0xffff00 0x000800 Sun UltraSPARC3 Extensions Required, ->>>48 lelong&0x3 0 total store ordering, ->>>48 lelong&0x3 1 partial store ordering, ->>>48 lelong&0x3 2 relaxed memory ordering, +>>>48 use elf-sparc 18 leshort 44 Siemens Tricore Embedded Processor, 18 leshort 45 Argonaut RISC Core, Argonaut Technologies Inc., 18 leshort 46 Renesas H8/300, diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/file-5.23/magic/Magdir/fortran new/file-5.24/magic/Magdir/fortran --- old/file-5.23/magic/Magdir/fortran 2014-09-11 17:03:07.000000000 +0200 +++ new/file-5.24/magic/Magdir/fortran 2015-07-08 14:05:39.000000000 +0200 @@ -1,7 +1,7 @@
#------------------------------------------------------------------------------
-# $File: fortran,v 1.8 2014/06/03 19:01:34 christos Exp $
+# $File: fortran,v 1.9 2015/06/17 19:55:27 christos Exp $
# FORTRAN source
-0 regex/100l \^[Cc][\ \t] FORTRAN program
+0 regex/100l \^[Cc][\ \t] FORTRAN program text
!:mime text/x-fortran
!:strength - 5
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/file-5.23/magic/Magdir/mail.news new/file-5.24/magic/Magdir/mail.news
--- old/file-5.23/magic/Magdir/mail.news 2014-09-11 17:03:07.000000000 +0200
+++ new/file-5.24/magic/Magdir/mail.news 2015-06-29 16:44:26.000000000 +0200
@@ -1,5 +1,5 @@
#------------------------------------------------------------------------------
-# $File: mail.news,v 1.22 2013/01/04 14:22:07 christos Exp $
+# $File: mail.news,v 1.23 2015/06/29 14:44:26 christos Exp $
# mail.news: file(1) magic for mail and news
#
# Unfortunately, saved netnews also has From line added in some news software.
@@ -41,6 +41,7 @@
# From: Simon Matter
15 byte 0
35 belong x \b, unit id %d -# 20 years after unix epoch 39 lelong x \b, serial %u ->>43 ledate/631152000 x \b, %s +# http://pub.ks-and-ks.ne.jp/cycling/edge500_fit.shtml +# 20 years after unix epoch +# TZ=GMT date -d '1989-12-31 0:00' +%s +>>43 leldate+631065600 x \b, %s
47 leshort x \b, manufacturer %d 47 leshort 1 \b (garmin) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/file-5.23/src/file.c new/file-5.24/src/file.c --- old/file-5.23/src/file.c 2015-06-03 21:49:20.000000000 +0200 +++ new/file-5.24/src/file.c 2015-06-11 16:15:53.000000000 +0200 @@ -32,7 +32,7 @@ #include "file.h"
#ifndef lint -FILE_RCSID("@(#)$File: file.c,v 1.164 2015/06/03 18:21:24 christos Exp $") +FILE_RCSID("@(#)$File: file.c,v 1.165 2015/06/11 12:52:32 christos Exp $") #endif /* lint */ #include "magic.h" @@ -89,10 +89,15 @@ private const char *separator = ":"; /* Default field separator */ private const struct option long_options[] = { +#define OPT_HELP 1 +#define OPT_APPLE 2 +#define OPT_EXTENSIONS 3 +#define OPT_MIME_TYPE 4 +#define OPT_MIME_ENCODING 5 #define OPT(shortname, longname, opt, doc) \ {longname, opt, NULL, shortname}, -#define OPT_LONGONLY(longname, opt, doc) \ - {longname, opt, NULL, 0}, +#define OPT_LONGONLY(longname, opt, doc, id) \ + {longname, opt, NULL, id}, #include "file_opts.h" #undef OPT #undef OPT_LONGONLY @@ -182,24 +187,20 @@ while ((c = getopt_long(argc, argv, OPTSTRING, long_options, &longindex)) != -1) switch (c) { - case 0 : - switch (longindex) { - case 0: - help(); - break; - case 10: - flags |= MAGIC_APPLE; - break; - case 11: - flags |= MAGIC_EXTENSION; - break; - case 12: - flags |= MAGIC_MIME_TYPE; - break; - case 13: - flags |= MAGIC_MIME_ENCODING; - break; - } + case OPT_HELP: + help(); + break; + case OPT_APPLE: + flags |= MAGIC_APPLE; + break; + case OPT_EXTENSIONS: + flags |= MAGIC_EXTENSION; + break; + case OPT_MIME_TYPE: + flags |= MAGIC_MIME_TYPE; + break; + case OPT_MIME_ENCODING: + flags |= MAGIC_MIME_ENCODING; break; case '0': nulsep = 1; @@ -595,7 +596,7 @@ #define OPT(shortname, longname, opt, doc) \ fprintf(stdout, " -%c, --" longname, shortname), \ docprint(doc); -#define OPT_LONGONLY(longname, opt, doc) \ +#define OPT_LONGONLY(longname, opt, doc, id) \ fprintf(stdout, " --" longname), \ docprint(doc); #include "file_opts.h" diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/file-5.23/src/file_opts.h new/file-5.24/src/file_opts.h --- old/file-5.23/src/file_opts.h 2015-06-03 21:49:20.000000000 +0200 +++ new/file-5.24/src/file_opts.h 2015-06-11 16:15:53.000000000 +0200 @@ -12,7 +12,7 @@ * switch statement! */ -OPT_LONGONLY("help", 0, " display this help and exit\n") +OPT_LONGONLY("help", 0, " display this help and exit\n", OPT_HELP) OPT('v', "version", 0, " output version information and exit\n") OPT('m', "magic-file", 1, " LIST use LIST as a colon-separated list of magic\n" " number files\n") @@ -29,10 +29,10 @@ OPT('F', "separator", 1, " STRING use string as separator instead of `:'\n") OPT('i', "mime", 0, " output MIME type strings (--mime-type and\n" " --mime-encoding)\n") -OPT_LONGONLY("apple", 0, " output the Apple CREATOR/TYPE\n") -OPT_LONGONLY("extension", 0, " output a slash-separated list of extnsions\n") -OPT_LONGONLY("mime-type", 0, " output the MIME type\n") -OPT_LONGONLY("mime-encoding", 0, " output the MIME encoding\n") +OPT_LONGONLY("apple", 0, " output the Apple CREATOR/TYPE\n", OPT_APPLE) +OPT_LONGONLY("extension", 0, " output a slash-separated list of extensions\n", OPT_EXTENSIONS) +OPT_LONGONLY("mime-type", 0, " output the MIME type\n", OPT_MIME_TYPE) +OPT_LONGONLY("mime-encoding", 0, " output the MIME encoding\n", OPT_MIME_ENCODING) OPT('k', "keep-going", 0, " don't stop at the first match\n") OPT('l', "list", 0, " list magic strength\n") #ifdef S_IFLNK diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/file-5.23/src/funcs.c new/file-5.24/src/funcs.c --- old/file-5.23/src/funcs.c 2015-06-10 02:43:47.000000000 +0200 +++ new/file-5.24/src/funcs.c 2015-07-08 14:05:39.000000000 +0200 @@ -27,7 +27,7 @@ #include "file.h" #ifndef lint -FILE_RCSID("@(#)$File: funcs.c,v 1.82 2015/06/03 18:01:20 christos Exp $") +FILE_RCSID("@(#)$File: funcs.c,v 1.83 2015/06/16 14:17:37 christos Exp $") #endif /* lint */ #include "magic.h" @@ -107,8 +107,10 @@ if (lineno != 0) { free(ms->o.buf); ms->o.buf = NULL; - file_printf(ms, "line %" SIZE_T_FORMAT "u: ", lineno); + file_printf(ms, "line %" SIZE_T_FORMAT "u:", lineno); } + if (ms->o.buf && *ms->o.buf) + file_printf(ms, " "); file_vprintf(ms, f, va); if (error > 0) file_printf(ms, " (%s)", strerror(error)); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/file-5.23/src/readelf.c new/file-5.24/src/readelf.c --- old/file-5.23/src/readelf.c 2015-04-09 22:01:41.000000000 +0200 +++ new/file-5.24/src/readelf.c 2015-07-08 14:05:39.000000000 +0200 @@ -27,7 +27,7 @@ #include "file.h" #ifndef lint -FILE_RCSID("@(#)$File: readelf.c,v 1.119 2015/04/09 20:01:41 christos Exp $") +FILE_RCSID("@(#)$File: readelf.c,v 1.120 2015/06/16 14:18:07 christos Exp $") #endif #ifdef BUILTIN_ELF @@ -1048,9 +1048,18 @@ break; } + /* Things we can determine when we seek */ switch (xsh_type) { case SHT_NOTE: + if (xsh_size + xsh_offset > (uintmax_t)fsize) { + if (file_printf(ms, + ", note offset/size 0x%jx+0x%jx exceeds" + " file size 0x%jx", (uintmax_t)xsh_offset, + (uintmax_t)xsh_size, (uintmax_t)fsize) == -1) + return -1; + return 0; + } if ((nbuf = malloc(xsh_size)) == NULL) { file_error(ms, errno, "Cannot allocate memory" " for note");