summaryrefslogtreecommitdiffstats
path: root/librdkafka-upstream.patch
diff options
context:
space:
mode:
authorRemi Collet <fedora@famillecollet.com>2016-01-11 13:25:36 +0100
committerRemi Collet <fedora@famillecollet.com>2016-01-11 13:25:36 +0100
commit866a582e4ef2f11590cfa9a8a67dc11cdd3c2f5f (patch)
treef3f0ce678d694077a81bb11b9d22d6cd8639b07b /librdkafka-upstream.patch
parent73845b9c79d7596983593db5239f66cdd6ef29e5 (diff)
librdkafka: add upstream patch for old glibc
Diffstat (limited to 'librdkafka-upstream.patch')
-rw-r--r--librdkafka-upstream.patch29
1 files changed, 29 insertions, 0 deletions
diff --git a/librdkafka-upstream.patch b/librdkafka-upstream.patch
new file mode 100644
index 0000000..062a9c3
--- /dev/null
+++ b/librdkafka-upstream.patch
@@ -0,0 +1,29 @@
+From ac916159a08ccb135a73891dc4e25b7be18223d2 Mon Sep 17 00:00:00 2001
+From: Magnus Edenhill <magnus@edenhill.se>
+Date: Mon, 11 Jan 2016 10:22:29 +0100
+Subject: [PATCH] Snappy endian swapping for older glibc 2.9 (issue #505, #407)
+
+---
+ src/snappy_compat.h | 6 +++++-
+ 1 file changed, 5 insertions(+), 1 deletion(-)
+
+diff --git a/src/snappy_compat.h b/src/snappy_compat.h
+index 5167a72..2c2375b 100644
+--- a/src/snappy_compat.h
++++ b/src/snappy_compat.h
+@@ -136,10 +136,14 @@ typedef unsigned long long u64;
+ #define __LITTLE_ENDIAN__ 1
+ #endif
+
+-#if __LITTLE_ENDIAN__ == 1 && (defined(__LSB_VERSION__) || defined(__WIN32__))
++#if __LITTLE_ENDIAN__ == 1 || defined(__WIN32__)
++#ifndef htole16
+ #define htole16(x) (x)
++#endif
++#ifndef le32toh
+ #define le32toh(x) (x)
+ #endif
++#endif
+
+
+ #if defined(_MSC_VER)