[cdrkit] faulty and unneeded memset caused a -Werror during build
Frantisek Kluknavsky
fkluknav at fedoraproject.org
Fri Feb 22 12:39:09 UTC 2013
commit 2636290d89e0c673d2f785a6d0e71df8ebc69cc9
Author: Frantisek Kluknavsky <fkluknav at redhat.com>
Date: Fri Feb 22 10:54:01 2013 +0100
faulty and unneeded memset caused a -Werror during build
cdrkit-1.1.11-memset.patch | 25 +++++++++++++++++++++++++
cdrkit.spec | 7 ++++++-
2 files changed, 31 insertions(+), 1 deletions(-)
---
diff --git a/cdrkit-1.1.11-memset.patch b/cdrkit-1.1.11-memset.patch
new file mode 100644
index 0000000..453bfbe
--- /dev/null
+++ b/cdrkit-1.1.11-memset.patch
@@ -0,0 +1,25 @@
+diff -up wrk/genisoimage/md5.c.wrk wrk/genisoimage/md5.c
+--- wrk/genisoimage/md5.c.wrk 2013-02-22 13:15:18.210866321 +0100
++++ wrk/genisoimage/md5.c 2013-02-22 13:15:29.979935133 +0100
+@@ -183,7 +183,7 @@ mk_MD5Final (unsigned char digest[16], s
+ putu32(ctx->buf[1], digest + 4);
+ putu32(ctx->buf[2], digest + 8);
+ putu32(ctx->buf[3], digest + 12);
+- memset(ctx, 0, sizeof(ctx)); /* In case it's sensitive */
++ memset(ctx, 0, sizeof(*ctx)); /* In case it's sensitive */
+ }
+
+ /* The four core functions - F1 is optimized somewhat */
+diff -up wrk/libedc/edcspeed.c.wrk wrk/libedc/edcspeed.c
+--- wrk/libedc/edcspeed.c.wrk 2013-02-22 10:45:33.353219110 +0100
++++ wrk/libedc/edcspeed.c 2013-02-22 10:46:52.497686387 +0100
+@@ -35,7 +35,8 @@ static int encspeed()
+ secs = 10;
+ end = 75*1000000 * secs;
+
+- memset(sect, 0, sizeof(sect));
++ //faulty and unneccessary, immediately rewritten again
++ //memset(sect, 0, sizeof(sect));
+ for (i=0; i < 2352; ) {
+ sect[i++] = 'J';
+ sect[i++] = 'S';
diff --git a/cdrkit.spec b/cdrkit.spec
index 99c6f62..d257559 100644
--- a/cdrkit.spec
+++ b/cdrkit.spec
@@ -1,7 +1,7 @@
Summary: A collection of CD/DVD utilities
Name: cdrkit
Version: 1.1.11
-Release: 15%{?dist}
+Release: 16%{?dist}
License: GPLv2
Group: Applications/System
URL: http://cdrkit.org/
@@ -22,6 +22,7 @@ Patch13: cdrkit-1.1.11-dvdman.patch
Patch14: cdrkit-1.1.11-paranoiacdda.patch
Patch15: cdrkit-1.1.11-utf8.patch
Patch16: cdrkit-1.1.11-cmakewarn.patch
+Patch17: cdrkit-1.1.11-edcspeed_memset.patch
BuildRequires: cmake libcap-devel zlib-devel perl file-devel bzip2-devel
@@ -130,6 +131,7 @@ SCSI devices.
# not using -b since otherwise backup files would be included into rpm
%patch15 -p1
%patch16 -p1 -b .cmakewarn
+%patch17 -p1 -b .edcspeed
# we do not want bundled paranoia library
rm -rf libparanoia
@@ -290,6 +292,9 @@ fi
%{_includedir}/usal
%changelog
+* Fri Feb 22 2013 Frantisek Kluknavsky <fkluknav at redhat.com> - 1.1.11-16
+- faulty and unneeded memset in edcspeed.c caused a -Werror during build
+
* Wed Feb 13 2013 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 1.1.11-15
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
More information about the scm-commits
mailing list