From 08a006d08a4c35d2c3ecc9a3d10cf7fd14661a84 Mon Sep 17 00:00:00 2001 From: Adam Weinberger Date: Tue, 29 Jul 2014 17:12:47 +0000 Subject: Rename all patches that contain '::' as a path separator, and use '__' instead. --- comms/lirc/files/patch-daemons__hw_srm7500libusb.c | 26 ++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 comms/lirc/files/patch-daemons__hw_srm7500libusb.c (limited to 'comms/lirc/files/patch-daemons__hw_srm7500libusb.c') diff --git a/comms/lirc/files/patch-daemons__hw_srm7500libusb.c b/comms/lirc/files/patch-daemons__hw_srm7500libusb.c new file mode 100644 index 000000000000..b9fe11431c2f --- /dev/null +++ b/comms/lirc/files/patch-daemons__hw_srm7500libusb.c @@ -0,0 +1,26 @@ +--- daemons/hw_srm7500libusb.c.orig ++++ daemons/hw_srm7500libusb.c +@@ -54,6 +54,23 @@ + #define USB_TIMEOUT (1000*10) + #define CONTROL_BUFFERSIZE 128 + ++#ifndef HAVE_STRNLEN ++size_t ++strnlen(const char *s, size_t maxlen) ++{ ++ size_t ret = strlen(s); ++ return ret > maxlen ? maxlen : ret; ++} ++#endif ++ ++#ifndef HAVE_STRCHRNUL ++char *strchrnul(const char *s, int ch) ++{ ++ char *ret = strchr(s, ch); ++ return ret == NULL ? ((char *)s) + strlen(s) : ret; ++} ++#endif ++ + static int srm7500_init(); + static int srm7500_deinit(); + static char *srm7500_rec(struct ir_remote *remotes); -- cgit v1.2.3