[SCM] pyliblo/master: Added patch to fix test, thanks to Sebastian Ramacher <sramacher at debian.org>
mira-guest at users.alioth.debian.org
mira-guest at users.alioth.debian.org
Wed Aug 28 10:13:50 UTC 2013
The following commit has been merged in the master branch:
commit 6cbab95fd88a5e3108ff3ca3d6a9e0a3a72222f4
Author: Jaromír Mikeš <mira.mikes at seznam.cz>
Date: Wed Aug 28 14:13:10 2013 +0200
Added patch to fix test, thanks to Sebastian Ramacher <sramacher at debian.org>
diff --git a/debian/patches/01-overflow.patch b/debian/patches/01-overflow.patch
new file mode 100644
index 0000000..9e92d1c
--- /dev/null
+++ b/debian/patches/01-overflow.patch
@@ -0,0 +1,32 @@
+Description: Fix python tests.
+Author: Sebastian Ramacher <sramacher at debian.org>
+Forwarded: no
+
+diff --git a/src/liblo.pyx b/src/liblo.pyx
+index 5ead6c4..e5215f4 100644
+--- a/src/liblo.pyx
++++ b/src/liblo.pyx
+@@ -25,6 +25,7 @@ from liblo cimport *
+ import inspect as _inspect
+ import weakref as _weakref
+
++from libc.stdint cimport int32_t, int64_t
+
+ class _weakref_method:
+ """
+@@ -777,10 +778,11 @@ cdef class Message:
+ lo_message_add_true(self._message)
+ elif value is False:
+ lo_message_add_false(self._message)
+- elif isinstance(value, int):
+- lo_message_add_int32(self._message, int(value))
+- elif isinstance(value, long):
+- lo_message_add_int64(self._message, long(value))
++ elif isinstance(value, (int, long)):
++ try:
++ lo_message_add_int32(self._message, <int32_t>value)
++ except OverflowError:
++ lo_message_add_int64(self._message, <int64_t>value)
+ elif isinstance(value, float):
+ lo_message_add_float(self._message, float(value))
+ elif isinstance(value, (bytes, unicode)):
diff --git a/debian/patches/series b/debian/patches/series
new file mode 100644
index 0000000..a2f90ec
--- /dev/null
+++ b/debian/patches/series
@@ -0,0 +1 @@
+01-overflow.patch
--
pyliblo packaging
More information about the pkg-multimedia-commits
mailing list