1.2.56 release, .spec cosmetics, add (minimalist) 'make check'

epel9
Rex Dieter 9 years ago
parent 4205aa8332
commit ce2cebdbdc

2
.gitignore vendored

@ -1 +1 @@
/libpng-1.2.50.tar.bz2
/libpng-1.2.56.tar.xz

@ -1,35 +0,0 @@
diff --git a/pngrtran.c b/pngrtran.c
index 7f0ff92..b57ce81 100644
--- a/pngrtran.c
+++ b/pngrtran.c
@@ -1216,6 +1216,9 @@ png_read_transform_info(png_structp png_ptr, png_infop info_ptr)
info_ptr->color_type = PNG_COLOR_TYPE_RGB;
info_ptr->bit_depth = 8;
info_ptr->num_trans = 0;
+
+ if (png_ptr->palette == NULL)
+ png_error (png_ptr, "Palette is NULL in indexed image");
}
else
{
diff --git a/pngset.c b/pngset.c
index 72d89fc..b1ce91d 100644
--- a/pngset.c
+++ b/pngset.c
@@ -461,6 +461,16 @@ png_set_PLTE(png_structp png_ptr, png_infop info_ptr,
return;
}
}
+ if ((num_palette > 0 && palette == NULL) ||
+ (num_palette == 0
+ # ifdef PNG_MNG_FEATURES_SUPPORTED
+ && (png_ptr->mng_features_permitted & PNG_FLAG_MNG_EMPTY_PLTE) == 0
+ # endif
+ ))
+ {
+ png_error(png_ptr, "Invalid palette");
+ return;
+ }
/* It may not actually be necessary to set png_ptr->palette here;
* we do it for backward compatibility with the way the png_handle_tRNS

@ -1,9 +1,8 @@
Summary: Old version of libpng, needed to run old binaries
Name: libpng12
Version: 1.2.50
Release: 9%{?dist}
Version: 1.2.56
Release: 1%{?dist}
License: zlib
Group: System Environment/Libraries
URL: http://www.libpng.org/pub/png/
# Obsolete old temporary packaging of libpng 1.2
@ -11,13 +10,13 @@ Obsoletes: libpng-compat <= 2:1.5.10
# Note: non-current tarballs get moved to the history/ subdirectory,
# so look there if you fail to retrieve the version you want
Source: ftp://ftp.simplesystems.org/pub/png/src/libpng-%{version}.tar.bz2
Source0: ftp://ftp.simplesystems.org/pub/png/src/libpng12/libpng-%{version}.tar.xz
Patch0: libpng12-multilib.patch
Patch1: libpng12-pngconf.patch
Patch2: libpng12-CVE-2013-6954.patch
BuildRequires: zlib-devel, pkgconfig
BuildRequires: pkgconfig
BuildRequires: zlib-devel
%description
The libpng12 package provides libpng 1.2, an older version of the libpng
@ -27,9 +26,8 @@ version of libpng.
%package devel
Summary: Development files for libpng 1.2
Group: Development/Libraries
Requires: %{name}%{?_isa} = %{version}-%{release}
Requires: zlib-devel%{?_isa} pkgconfig%{?_isa}
Requires: zlib-devel%{?_isa}
%description devel
The libpng12-devel package contains header files and documentation necessary
@ -40,7 +38,6 @@ for developing programs using libpng12.
%patch0 -p1
%patch1 -p1
%patch2 -p1
%build
%configure \
@ -65,12 +62,15 @@ rm -fv $RPM_BUILD_ROOT%{_libdir}/libpng.so
rm -fv $RPM_BUILD_ROOT%{_libdir}/pkgconfig/libpng.pc
rm -fv $RPM_BUILD_ROOT%{_mandir}/man3/{libpng,libpngpf}.3*
%post -p /sbin/ldconfig
%check
make check
%post -p /sbin/ldconfig
%postun -p /sbin/ldconfig
%files
%doc LICENSE
%{!?_licensedir:%global license %%doc}
%license LICENSE
%doc libpng-%{version}.txt README TODO CHANGES
%{_libdir}/libpng12.so.0*
@ -82,6 +82,9 @@ rm -fv $RPM_BUILD_ROOT%{_mandir}/man3/{libpng,libpngpf}.3*
%{_libdir}/pkgconfig/libpng12.pc
%changelog
* Mon Dec 21 2015 Rex Dieter <rdieter@fedoraproject.org> 1.2.56-1
- 1.2.56 release, .spec cosmetics, add (minimalist) 'make check'
* Wed Jun 17 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.2.50-9
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild

@ -1 +1 @@
717caa58e9c71a80820eb38c4f4d6ec3 libpng-1.2.50.tar.bz2
868562bd1c58b76ed8703f135a2e439a libpng-1.2.56.tar.xz

Loading…
Cancel
Save