[abe] * Mon Mar 14 2011 Jerry James <loganjerry at gmail.com> - 1.1-13 - Fix double free (bz 509052) - Fix in
Jerry James
jjames at fedoraproject.org
Mon Mar 14 17:00:25 UTC 2011
commit 97aa039229754b68c51d54b09570f2ba5d0eda08
Author: Jerry James <loganjerry at gmail.com>
Date: Mon Mar 14 10:59:57 2011 -0600
* Mon Mar 14 2011 Jerry James <loganjerry at gmail.com> - 1.1-13
- Fix double free (bz 509052)
- Fix incorrectly-sized format specifier
- Don't use abe's extra optimization and debugging CFLAGS (fixes debuginfo)
- Remove filename extension from Icon field in desktop file
- Remove BuildRoot tag
- Add post/postun scripts, fix Requires for those scripts
abe-1.1-doublefree.patch | 11 +++++++++++
abe-1.1-format.patch | 11 +++++++++++
abe.spec | 29 ++++++++++++++++++++++++-----
3 files changed, 46 insertions(+), 5 deletions(-)
---
diff --git a/abe-1.1-doublefree.patch b/abe-1.1-doublefree.patch
new file mode 100644
index 0000000..41ae69b
--- /dev/null
+++ b/abe-1.1-doublefree.patch
@@ -0,0 +1,11 @@
+--- src/Main.c.orig 2005-03-05 09:20:04.000000000 -0700
++++ src/Main.c 2011-03-14 10:08:31.846413904 -0600
+@@ -35,8 +35,6 @@
+ for(i = 0; modes[i]; ++i)
+ printf("\t%d x %d\n", modes[i]->w, modes[i]->h);
+ }
+-
+- free(modes);
+ }
+
+ void
diff --git a/abe-1.1-format.patch b/abe-1.1-format.patch
new file mode 100644
index 0000000..129f5ce
--- /dev/null
+++ b/abe-1.1-format.patch
@@ -0,0 +1,11 @@
+--- src/MapIO.c.orig 2005-03-05 09:20:04.000000000 -0700
++++ src/MapIO.c 2011-03-14 10:15:33.166949366 -0600
+@@ -93,7 +93,7 @@
+ // compression step 1: read compressed data from disk
+ // FIXME: what would be nicer is to only allocate as much mem as used on disk.
+ size = LEVEL_COUNT * map.w * map.h;
+- printf("size %u\n", size);
++ printf("size %zu\n", size);
+ fflush(stdout);
+ if(!(read_buff = (Uint16 *) malloc(sizeof(Uint16) * size))) {
+ fprintf(stderr, "Out of memory on map read.");
diff --git a/abe.spec b/abe.spec
index fced545..9db501d 100644
--- a/abe.spec
+++ b/abe.spec
@@ -1,6 +1,6 @@
Name: abe
Version: 1.1
-Release: 12%{?dist}
+Release: 13%{?dist}
Summary: Scrolling, platform-jumping, ancient pyramid exploring game
Group: Amusements/Games
@@ -9,13 +9,14 @@ URL: http://abe.sourceforge.net/
Source0: http://downloads.sourceforge.net/abe/abe-%{version}.tar.gz
Source1: %{name}.png
Patch0: abe-1.1-settings.patch
+Patch1: abe-1.1-doublefree.patch
+Patch2: abe-1.1-format.patch
-BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildRequires: SDL-devel >= 1.2.3, SDL_mixer-devel >= 1.2.3
BuildRequires: libXmu-devel libXi-devel
BuildRequires: desktop-file-utils
-Requires(post): coreutils
-Requires(postun): coreutils
+Requires(post): desktop-file-utils
+Requires(postun): desktop-file-utils
%description
A scrolling, platform-jumping, key-collecting, ancient pyramid exploring game,
@@ -24,9 +25,12 @@ vaguely in the style of similar games for the Commodore+4.
%prep
%setup -q
%patch0 -p1
+%patch1
+%patch2
%build
%configure --with-data-dir=%{_datadir}/%{name}
+sed -i "s/^CFLAGS =.*/CFLAGS = ${RPM_OPT_FLAGS} \$\(SDL_CFLAGS\)/" src/Makefile
make %{?_smp_mflags}
%install
@@ -45,7 +49,7 @@ cat << EOF > %{name}.desktop
Name=Abe
Comment="Abe's Amazing Adventure"
Exec=abe
-Icon=abe.png
+Icon=abe
Terminal=false
Type=Application
Encoding=UTF-8
@@ -57,6 +61,13 @@ desktop-file-install --vendor fedora --dir $RPM_BUILD_ROOT/%{_datadir}/applicati
%clean
rm -rf $RPM_BUILD_ROOT
+%post
+update-desktop-database %{_datadir}/applications &>/dev/null
+
+%postun
+if [ $1 -eq 0 ]; then
+ update-desktop-database %{_datadir}/applications &>/dev/null
+fi
%files
%defattr(-,root,root,-)
@@ -67,6 +78,14 @@ rm -rf $RPM_BUILD_ROOT
%{_datadir}/pixmaps/%{name}.png
%changelog
+* Mon Mar 14 2011 Jerry James <loganjerry at gmail.com> - 1.1-13
+- Fix double free (bz 509052)
+- Fix incorrectly-sized format specifier
+- Don't use abe's extra optimization and debugging CFLAGS (fixes debuginfo)
+- Remove filename extension from Icon field in desktop file
+- Remove BuildRoot tag
+- Add post/postun scripts, fix Requires for those scripts
+
* Mon Feb 07 2011 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 1.1-12
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
More information about the scm-commits
mailing list