[libopensync-plugin-opie] Fix FTBFS with gcc-4.8 (#914140, #992107)
Andreas Bierfert
awjb at fedoraproject.org
Fri Jun 20 15:23:06 UTC 2014
commit 60f7a87e03bd6d15e3eb340acb5d6006ec31ea20
Author: Andreas Bierfert <andreas.bierfert at lowlatency.de>
Date: Fri Jun 20 17:23:00 2014 +0200
Fix FTBFS with gcc-4.8 (#914140, #992107)
- Fix FTBFS with -Werror=format-security (#1106050)
libopensync-plugin-opie-format-security.patch | 13 ++++++++++++
libopensync-plugin-opie-gcc48.patch | 27 +++++++++++++++++++++++++
libopensync-plugin-opie.spec | 10 ++++++++-
3 files changed, 49 insertions(+), 1 deletions(-)
---
diff --git a/libopensync-plugin-opie-format-security.patch b/libopensync-plugin-opie-format-security.patch
new file mode 100644
index 0000000..bbad967
--- /dev/null
+++ b/libopensync-plugin-opie-format-security.patch
@@ -0,0 +1,13 @@
+diff --git a/src/opie_debug.h b/src/opie_debug.h
+index 364c06b..292fedb 100644
+--- a/src/opie_debug.h
++++ b/src/opie_debug.h
+@@ -32,7 +32,7 @@
+ #include <glib.h>
+
+ #ifndef OPIE_DEBUG
+-#define OPIE_DEBUG(x) (printf(x))
++#define OPIE_DEBUG(x) (printf("%s", x))
+ #endif
+
+ /* Use the OPIE_PRINT macro instead of printf.
diff --git a/libopensync-plugin-opie-gcc48.patch b/libopensync-plugin-opie-gcc48.patch
new file mode 100644
index 0000000..29d3e8f
--- /dev/null
+++ b/libopensync-plugin-opie-gcc48.patch
@@ -0,0 +1,27 @@
+diff --git a/src/opie_qcop.c b/src/opie_qcop.c
+index 5090a18..a3ac162 100644
+--- a/src/opie_qcop.c
++++ b/src/opie_qcop.c
+@@ -541,11 +541,11 @@ void monitor_thread_main(qcop_monitor_data* data)
+
+ static const char *base64_alphabet = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";
+
+-static void opie_base64_init(char *rank)
++static void opie_base64_init(char *rank, size_t bufsize)
+ {
+ int i;
+
+- memset(rank, 0xff, sizeof(rank));
++ memset(rank, 0xff, bufsize);
+ for (i=0;i<64;i++) {
+ rank[(unsigned int)base64_alphabet[i]] = i;
+ }
+@@ -565,7 +565,7 @@ static void opie_base64_init(char *rank)
+ static size_t opie_base64_decode_step(unsigned char *in, size_t len, unsigned char *out, int *state, unsigned int *save)
+ {
+ unsigned char base64_rank[256];
+- opie_base64_init((char*)base64_rank);
++ opie_base64_init((char*)base64_rank, sizeof(base64_rank));
+
+ register unsigned char *inptr, *outptr;
+ unsigned char *inend, c;
diff --git a/libopensync-plugin-opie.spec b/libopensync-plugin-opie.spec
index 91f7c93..37f91f6 100644
--- a/libopensync-plugin-opie.spec
+++ b/libopensync-plugin-opie.spec
@@ -1,7 +1,7 @@
Name: libopensync-plugin-opie
Epoch: 1
Version: 0.22
-Release: 11%{?dist}
+Release: 12%{?dist}
Summary: Synchronisation with the Opie handheld environment
Group: System Environment/Libraries
@@ -12,6 +12,8 @@ Source0: http://www.opensync.org/download/releases/%{version}/%{name}-%{v
Source1: PACKAGE-LICENSING
Patch0: libopensync-plugin-opie-curl-setopt.patch
Patch1: libopensync-plugin-opie-curl-include.patch
+Patch2: libopensync-plugin-opie-gcc48.patch
+Patch3: libopensync-plugin-opie-format-security.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildRequires: libopensync-devel = 1:0.22
@@ -26,6 +28,8 @@ handheld environment (http://opie.handhelds.org).
%setup -q
%patch0 -b curlsetopt
%patch1 -p1 -b curlinclude
+%patch2 -p1 -b .gcc48
+%patch3 -p1 -b .format-security
%build
%configure
@@ -50,6 +54,10 @@ rm -rf $RPM_BUILD_ROOT
%{_datadir}/opensync/defaults/opie-sync
%changelog
+* Mon Jun 16 2014 Yaakov Selkowitz <yselkowi at redhat.com> - 1:0.22-12
+- Fix FTBFS with gcc-4.8 (#914140, #992107)
+- Fix FTBFS with -Werror=format-security (#1106050)
+
* Sat Jun 07 2014 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 1:0.22-11
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
More information about the scm-commits
mailing list