[gnome-xcf-thumbnailer] Revert "Dead upstream"

Bastien Nocera hadess at fedoraproject.org
Mon Jan 23 16:55:35 UTC 2012


commit 228c397debfc8ce59c8c139f8115614ef1f7c8a8
Author: Bastien Nocera <hadess at hadess.net>
Date:   Mon Jan 23 16:55:23 2012 +0000

    Revert "Dead upstream"
    
    This reverts commit eb914e7404677c24b2862efb42bb7d6eaa4f1f68.

 .gitignore                                    |    2 +
 dead.package                                  |    1 -
 gnome-xcf-thumbnailer-1.0-CVE-2009-2175.patch |   45 +++++++++++++
 gnome-xcf-thumbnailer-1.0-libpng15.patch      |   15 ++++
 gnome-xcf-thumbnailer.spec                    |   87 +++++++++++++++++++++++++
 sources                                       |    1 +
 6 files changed, 150 insertions(+), 1 deletions(-)
---
diff --git a/.gitignore b/.gitignore
new file mode 100644
index 0000000..40bd276
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,2 @@
+gnome-xcf-thumbnailer-1.0.tar.bz2
+/gnome-xcf-thumbnailer-1.0.tar.bz2
diff --git a/gnome-xcf-thumbnailer-1.0-CVE-2009-2175.patch b/gnome-xcf-thumbnailer-1.0-CVE-2009-2175.patch
new file mode 100644
index 0000000..c06816e
--- /dev/null
+++ b/gnome-xcf-thumbnailer-1.0-CVE-2009-2175.patch
@@ -0,0 +1,45 @@
+Index: flatten.c
+===================================================================
+RCS file: /home/makcvs/repository/source/xcftools/flatten.c,v
+retrieving revision 1.27
+diff -u -r1.27 flatten.c
+--- flatten.c	22 Feb 2006 00:01:04 -0000	1.27
++++ flatten.c	18 Jun 2009 23:11:42 -0000
+@@ -619,14 +619,14 @@
+   fillTile(&toptile,0);
+ 
+   for( where.t = spec->dim.c.t; where.t < spec->dim.c.b; where.t=where.b ) {
+-    where.b = (where.t+TILE_HEIGHT) - where.t % TILE_HEIGHT ;
++    where.b = TILE_TOP(where.t)+TILE_HEIGHT ;
+     if( where.b > spec->dim.c.b ) where.b = spec->dim.c.b ;
+     nrows = where.b - where.t ;
+     for( y = 0; y < nrows ; y++ )
+       rows[y] = xcfmalloc(4*(spec->dim.c.r-spec->dim.c.l));
+ 
+     for( where.l = spec->dim.c.l; where.l < spec->dim.c.r; where.l=where.r ) {
+-      where.r = (where.l+TILE_WIDTH) - where.l % TILE_WIDTH ;
++      where.r = TILE_LEFT(where.l)+TILE_WIDTH ;
+       if( where.r > spec->dim.c.r ) where.r = spec->dim.c.r ;
+       ncols = where.r - where.l ;
+ 
+Index: xcftools.h
+===================================================================
+RCS file: /home/makcvs/repository/source/xcftools/xcftools.h,v
+retrieving revision 1.17
+diff -u -r1.17 xcftools.h
+--- xcftools.h	13 Feb 2006 03:04:03 -0000	1.17
++++ xcftools.h	18 Jun 2009 23:11:42 -0000
+@@ -146,6 +146,13 @@
+ /* These are hardcoded in the Gimp sources: */
+ #define TILE_WIDTH 64
+ #define TILE_HEIGHT 64
++/* These definitions of TILE_LEFT and TILE_TOP work correctly for negative
++ * numbers, but on the other hand depend on TILE_WIDTH and TILE_HEIGHT
++ * being powers of 2. That's okay, because the tile size cannot change
++ * anyway.
++ */
++#define TILE_LEFT(x) ((x) & -TILE_WIDTH)
++#define TILE_TOP(y) ((y) & -TILE_HEIGHT)
+ 
+ struct tileDimensions {
+   struct rect c ;
diff --git a/gnome-xcf-thumbnailer-1.0-libpng15.patch b/gnome-xcf-thumbnailer-1.0-libpng15.patch
new file mode 100644
index 0000000..e426c08
--- /dev/null
+++ b/gnome-xcf-thumbnailer-1.0-libpng15.patch
@@ -0,0 +1,15 @@
+diff -up gnome-xcf-thumbnailer-1.0/xcf2png.c.orig gnome-xcf-thumbnailer-1.0/xcf2png.c
+--- gnome-xcf-thumbnailer-1.0/xcf2png.c.orig	2006-02-13 01:09:10.000000000 +0100
++++ gnome-xcf-thumbnailer-1.0/xcf2png.c	2011-12-06 02:01:17.644264002 +0100
+@@ -71,9 +71,9 @@ init_output(void)
+   
+   outfile = openout(flatspec.output_filename);
+   libpng = png_create_write_struct(PNG_LIBPNG_VER_STRING,
+-                                   png_voidp_NULL,
++                                   NULL,
+                                    my_error_callback,
+-                                   png_error_ptr_NULL);
++                                   NULL);
+   if( !libpng )
+     FatalUnexpected(_("Couldn't initialize libpng library"));
+   
diff --git a/gnome-xcf-thumbnailer.spec b/gnome-xcf-thumbnailer.spec
new file mode 100644
index 0000000..9b99d7d
--- /dev/null
+++ b/gnome-xcf-thumbnailer.spec
@@ -0,0 +1,87 @@
+Name:           gnome-xcf-thumbnailer
+Version:        1.0
+Release:        8%{?dist}
+Summary:        Thumbnailer for XCF files
+
+Group:          Amusements/Graphics
+License:        GPLv2+
+URL:            http://ftp.gnome.org/pub/GNOME/sources/gnome-xcf-thumbnailer/
+Source0:        http://download.gnome.org/sources/%{name}/%{version}/%{name}-%{version}.tar.bz2
+# Fix CVE-2009-2175 (see RHBZ #647907)
+Patch0:         gnome-xcf-thumbnailer-1.0-CVE-2009-2175.patch
+# Fix compilation against libpng 1.5
+Patch1:         gnome-xcf-thumbnailer-1.0-libpng15.patch
+
+BuildRequires:  GConf2
+BuildRequires:  glib2-devel
+BuildRequires:  libpng-devel
+BuildRequires:  popt-devel
+Requires(pre):  GConf2
+Requires(post): GConf2
+Requires(preun):GConf2
+
+%description
+Thumbnailer for GIMP's own format, XCF files.
+
+
+%prep
+%setup -q
+%patch0 -p0 -b .CVE-2009-2175
+%patch1 -p1 -b .libpng15
+
+
+%build
+%configure \
+  --disable-schemas-install
+make %{?_smp_mflags}
+
+
+%install
+make install DESTDIR=$RPM_BUILD_ROOT
+
+
+%pre
+%gconf_schema_prepare %{name}
+
+
+%post
+%gconf_schema_upgrade %{name}
+
+
+%preun
+%gconf_schema_remove %{name}
+
+
+%files
+%defattr(-,root,root,-)
+%doc AUTHORS ChangeLog COPYING NEWS TODO
+%{_bindir}/gnome-xcf-thumbnailer
+%{_sysconfdir}/gconf/schemas/*.schemas
+
+
+%changelog
+* Fri Jan 13 2012 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 1.0-8
+- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
+
+* Tue Dec 06 2011 Mohamed El Morabity <melmorabity at fedoraproject.org> - 1.0-7
+- Fix compilation agains libpng 1.5
+- Spec cleanup
+
+* Tue Dec 06 2011 Adam Jackson <ajax at redhat.com> - 1.0-6
+- Rebuild for new libpng
+
+* Tue Feb 08 2011 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 1.0-5
+- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
+
+* Fri Oct 29 2010 rpmbuild <pikachu.2014 at gmail.com> - 1.0-4
+- Fix RHBZ #64797 (CVE-2009-2175)
+- Update GConf scriptlets to latest specifications
+
+* Tue Feb 17 2010 ELMORABITY Mohamed <melmorabity at fedoraproject.org> 1.0-3
+- Remove %%config tag for GConf schema files
+
+* Tue Jan 26 2010 ELMORABITY Mohamed <melmorabity at fedoraproject.org> 1.0-2
+- Update %%files section
+
+* Tue Dec 29 2009 ELMORABITY Mohamed <melmorabity at fedoraproject.org> 1.0-1
+- Initial RPM release
diff --git a/sources b/sources
new file mode 100644
index 0000000..76134d5
--- /dev/null
+++ b/sources
@@ -0,0 +1 @@
+5853d69a19271aa102f1df84e7ccebb6  gnome-xcf-thumbnailer-1.0.tar.bz2


More information about the scm-commits mailing list