summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichał Górny <mgorny@gentoo.org>2019-11-05 23:34:37 +0100
committerMichał Górny <mgorny@gentoo.org>2019-11-05 23:34:43 +0100
commitae1e24fcf7e40e90f37be07085a1743127d4f4cf (patch)
treef076c36c2a0aefcda4aec0ee896233137a94fb19 /net-libs
parentapp-benchmarks/volanomark: Remove last-rited pkg (diff)
downloadgentoo-ae1e24fcf7e40e90f37be07085a1743127d4f4cf.tar.gz
gentoo-ae1e24fcf7e40e90f37be07085a1743127d4f4cf.tar.bz2
gentoo-ae1e24fcf7e40e90f37be07085a1743127d4f4cf.zip
net-libs/openslp: Remove last-rited pkg
Bug: https://bugs.gentoo.org/662878 Signed-off-by: Michał Górny <mgorny@gentoo.org>
Diffstat (limited to 'net-libs')
-rw-r--r--net-libs/openslp/Manifest2
-rw-r--r--net-libs/openslp/files/openslp-1.2.1-cflags.patch11
-rw-r--r--net-libs/openslp/files/openslp-1.2.1-fbsd.patch12
-rw-r--r--net-libs/openslp/files/openslp-1.2.1-fixoverflow.patch11
-rw-r--r--net-libs/openslp/files/openslp-2.0.0-CVE-2012-4428.patch51
-rw-r--r--net-libs/openslp/files/openslp-2.0.0-CVE-2016-4912.patch15
-rw-r--r--net-libs/openslp/files/openslp-2.0.0-CVE-2016-7567.patch94
-rw-r--r--net-libs/openslp/files/openslp-2.0.0-cflags.patch25
-rw-r--r--net-libs/openslp/files/openslp-2.0.0-namespace.patch773
-rw-r--r--net-libs/openslp/files/slpd-init88
-rw-r--r--net-libs/openslp/files/slpd.service10
-rw-r--r--net-libs/openslp/metadata.xml11
-rw-r--r--net-libs/openslp/openslp-1.2.1-r3.ebuild43
-rw-r--r--net-libs/openslp/openslp-2.0.0-r4.ebuild43
-rw-r--r--net-libs/openslp/openslp-2.0.0-r5.ebuild44
15 files changed, 0 insertions, 1233 deletions
diff --git a/net-libs/openslp/Manifest b/net-libs/openslp/Manifest
deleted file mode 100644
index d053948ce49a..000000000000
--- a/net-libs/openslp/Manifest
+++ /dev/null
@@ -1,2 +0,0 @@
-DIST openslp-1.2.1.tar.gz 886195 BLAKE2B f4ccdf37028d41b6e405768f1b3982b1eaa89e85a7e0f3b24c2a29195d39465807f967845958baaa567a7dd2d2bc8cff55eb1d910f43a6e54276673719596c9e SHA512 34742d88e772d7dba5c6fab1ccb7bf27d6174c5ca429aec406472994bcd806bfaf16dd86fce2ae4c51659587e99cced2436cf36772f6e086f7b87275fb1b19b6
-DIST openslp-2.0.0.tar.gz 5424646 BLAKE2B f63560742cb3f679d052fb48b0afdd7cc7995806d77ef93f01da3cd80a884a840d0b678927685d4f4138358dfcf10e93269217643e399d7721571251c31fcbe5 SHA512 e7627417d45d5d0cc83d6e13d62fe192702ce7b763f1b4fb51aa5da8285405b16a34c3ac4f0a1ecffdf59557b29ec7d24925941e56ddee277c8897162f597ade
diff --git a/net-libs/openslp/files/openslp-1.2.1-cflags.patch b/net-libs/openslp/files/openslp-1.2.1-cflags.patch
deleted file mode 100644
index a9a1d2634e7f..000000000000
--- a/net-libs/openslp/files/openslp-1.2.1-cflags.patch
+++ /dev/null
@@ -1,11 +0,0 @@
-diff -ruN openslp-1.2.1.orig/configure.in openslp-1.2.1/configure.in
---- openslp-1.2.1.orig/configure.in 2005-02-15 21:06:02.000000000 +0100
-+++ openslp-1.2.1/configure.in 2012-01-24 23:49:13.000000000 +0100
-@@ -153,7 +153,6 @@
- OPTFLAGS="-O"
- fi
- fi
--CFLAGS="$CFLAGS $OPTFLAGS"
-
- dnl ***********************************************************************
- dnl Checks for header files.
diff --git a/net-libs/openslp/files/openslp-1.2.1-fbsd.patch b/net-libs/openslp/files/openslp-1.2.1-fbsd.patch
deleted file mode 100644
index dac041516f23..000000000000
--- a/net-libs/openslp/files/openslp-1.2.1-fbsd.patch
+++ /dev/null
@@ -1,12 +0,0 @@
-Index: openslp-1.2.1/common/Makefile.am
-===================================================================
---- openslp-1.2.1.orig/common/Makefile.am
-+++ openslp-1.2.1/common/Makefile.am
-@@ -24,6 +24,7 @@ libcommonlibslp_la_SOURCES = \
- slp_parse.c \
- slp_pid.c \
- slp_dhcp.c \
-+ slp_net.c \
- $(slp_v1message_SRCS) \
- $(slp_security_SRCS)
-
diff --git a/net-libs/openslp/files/openslp-1.2.1-fixoverflow.patch b/net-libs/openslp/files/openslp-1.2.1-fixoverflow.patch
deleted file mode 100644
index c02d8407fb3b..000000000000
--- a/net-libs/openslp/files/openslp-1.2.1-fixoverflow.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/openslp-1.2.1/slpd/slpd_socket.c 2010-09-11 16:31:47.325871093 -0500
-+++ b/openslp-1.2.1/slpd/slpd_socket.c 2010-09-11 16:31:55.706851189 -0500
-@@ -183,7 +183,7 @@
- memcpy(&mreq.imr_multiaddr, maddr, sizeof(struct in_addr));
-
- /* drop for the specified interface */
-- memcpy(&mreq.imr_interface,addr,sizeof(addr));
-+ memcpy(&mreq.imr_interface,addr,sizeof(struct in_addr));
-
- return setsockopt(sockfd, IPPROTO_IP, IP_DROP_MEMBERSHIP, (char*)&mreq,sizeof(mreq));
- }
diff --git a/net-libs/openslp/files/openslp-2.0.0-CVE-2012-4428.patch b/net-libs/openslp/files/openslp-2.0.0-CVE-2012-4428.patch
deleted file mode 100644
index 28564c007cf3..000000000000
--- a/net-libs/openslp/files/openslp-2.0.0-CVE-2012-4428.patch
+++ /dev/null
@@ -1,51 +0,0 @@
-
-Description: Fix out-of-bounds buffer access (CVE-2012-4428)
- Fix handling of string-list in common/slp_common.c by not increasing
- the item pointer past the string-list pointer, and letting '\\' only
- escape the item separator ','.
-Author: Guillem Jover <guillem@debian.org>
-Origin: vendor
-Bug: http://sourceforge.net/p/openslp/bugs/122/
-Bug-Debian: https://bugs.debian.org/687597
-Last-Update: 2014-07-25
-
-Strangely nobody seems to have fixed this in openslp-2.0.0 ever.
-Patch forward-ported; one chunk isn't needed anymore as the code has been
-independently rewritten. Andreas K. Hüttel <dilfridge@gentoo.org>
-
-
-diff -ruN openslp-2.0.0.orig/common/slp_compare.c openslp-2.0.0/common/slp_compare.c
---- openslp-2.0.0.orig/common/slp_compare.c 2012-12-12 20:12:43.000000000 +0100
-+++ openslp-2.0.0/common/slp_compare.c 2017-02-18 19:59:55.296473698 +0100
-@@ -587,13 +587,10 @@
- /* seek to the end of the next list item */
- while(1)
- {
-- if(itemend == listend || *itemend == ',')
-- {
-- if(*(itemend - 1) != '\\')
-- {
-- break;
-- }
-- }
-+ if(itemend == listend)
-+ break;
-+ if(*itemend == ',' && *(itemend - 1) != '\\')
-+ break;
-
- itemend++;
- }
-@@ -683,9 +680,10 @@
- /* seek to the end of the next list item */
- while (1)
- {
-- if (itemend == listend || *itemend == ',')
-- if (*(itemend - 1) != '\\')
-- break;
-+ if(itemend == listend)
-+ break;
-+ if(*itemend == ',' && *(itemend - 1) != '\\')
-+ break;
- itemend++;
- }
-
diff --git a/net-libs/openslp/files/openslp-2.0.0-CVE-2016-4912.patch b/net-libs/openslp/files/openslp-2.0.0-CVE-2016-4912.patch
deleted file mode 100644
index d8a0eca0d3d3..000000000000
--- a/net-libs/openslp/files/openslp-2.0.0-CVE-2016-4912.patch
+++ /dev/null
@@ -1,15 +0,0 @@
-Source: https://src.fedoraproject.org/cgit/rpms/openslp.git/plain/openslp-2.0.0-null-pointer-deref.patch
-See also https://bugs.gentoo.org/show_bug.cgi?id=583396
-
-diff -up openslp-2.0.0/common/slp_xmalloc.c.orig openslp-2.0.0/common/slp_xmalloc.c
---- openslp-2.0.0/common/slp_xmalloc.c.orig 2012-12-07 01:52:08.000000000 +0100
-+++ openslp-2.0.0/common/slp_xmalloc.c 2016-05-23 12:58:57.953532979 +0200
-@@ -203,6 +203,8 @@ void * _xrealloc(const char * file, int
- if (x->size != size)
- {
- newptr = _xmalloc(file, line, size);
-+ if (newptr == 0)
-+ return 0;
- memcpy(newptr, ptr, x->size);
- _xfree(file, line, x);
- }
diff --git a/net-libs/openslp/files/openslp-2.0.0-CVE-2016-7567.patch b/net-libs/openslp/files/openslp-2.0.0-CVE-2016-7567.patch
deleted file mode 100644
index 2d54fa04bfce..000000000000
--- a/net-libs/openslp/files/openslp-2.0.0-CVE-2016-7567.patch
+++ /dev/null
@@ -1,94 +0,0 @@
-See
-http://www.openwall.com/lists/oss-security/2016/09/27/4
-https://bugs.gentoo.org/show_bug.cgi?id=595542
-
-diff -r 598821da69f2 -r 34fb3aa5e6b4 openslp/common/slp_compare.c
---- a/common/slp_compare.c Sat Jun 08 15:14:45 2013 -0600
-+++ b/common/slp_compare.c Mon Nov 30 20:50:12 2015 -0700
-@@ -194,7 +194,8 @@
- * @return The new (shorter) length of @p str.
- *
- * @note This routine assumes that leading and trailing white space have
-- * already been removed from @p str.
-+ * already been removed from @p str. It also assumes that @p str may
-+ * not be null-terminated.
- */
- static int SLPFoldWhiteSpace(size_t len, char * str)
- {
-@@ -203,11 +204,11 @@
- {
- if (isspace(*p))
- {
-- char * ws2p = ++p; /* Point ws2p to the second ws char. */
-- while (isspace(*p)) /* Scan till we hit a non-ws char. */
-+ char * ws2p = ++p; /* Point ws2p to the second ws char. */
-+ while (p < ep && isspace(*p)) /* Scan till we hit a non-ws char. */
- p++;
-- len -= p - ws2p; /* Reduce the length by extra ws. */
-- memmove(ws2p, p, ep - p); /* Overwrite the extra white space. */
-+ len -= p - ws2p; /* Reduce the length by extra ws. */
-+ memmove(ws2p, p, ep - p); /* Overwrite the extra white space. */
- }
- p++;
- }
-@@ -821,6 +822,50 @@
-
- #ifdef SLP_COMPARE_TEST
-
-+/* Test boundary conditions of SLPFoldWhiteSpace. */
-+static int test_SLPFoldWhiteSpace(void)
-+{
-+ static char test_str0[] = " ";
-+ static char test_str1[] = "Blah";
-+ static char test_str3[] = "Blah blah";
-+ static char test_str4[] = "Blah blah";
-+ static char test_str5[] = "Blah blah blah";
-+ static char test_str8[] = " Blah blah";
-+ static char test_str9[] = " Blah blah";
-+ static char test_strC[] = "Blah blah ";
-+ static char test_strD[] = "Blah blah xxxx";
-+
-+ static char * test_strs[] =
-+ {
-+ test_str0, test_str0, test_str0, test_str1, test_strC,
-+ test_str3, test_str4, test_str5, test_strC, test_strC,
-+ test_str8, test_str9, test_strC, test_strD,
-+ };
-+
-+ static int test_lens[] =
-+ {
-+ 0, 1, 2, 4, 9, 10, 11, 15, 10, 11, 10, 11, 11, 11,
-+ };
-+
-+ static int test_fins[] =
-+ {
-+ 0, 1, 1, 4, 9, 9, 9, 14, 10, 10, 10, 10, 10, 10,
-+ };
-+
-+#define MAX_BUFSZ 32
-+
-+ int i;
-+ for (i = 0; i < sizeof(test_strs) / sizeof(*test_strs); ++i)
-+ {
-+ char test_buf[MAX_BUFSZ];
-+ memmove(test_buf, test_strs[i], test_lens[i]);
-+ int len = SLPFoldWhiteSpace(test_lens[i], test_buf);
-+ if (len != test_fins[i])
-+ return -1;
-+ }
-+ return 0;
-+}
-+
- /* ---------------- Test main for the slp_compare.c module ----------------
- *
- * Compile with:
-@@ -840,6 +885,9 @@
-
- int count;
-
-+ if (test_SLPFoldWhiteSpace() != 0)
-+ return -1;
-+
- /* *** SLPContainsStringList ***
- */
- count = SLPContainsStringList(sizeof lst1 - 1, lst1, sizeof str1 - 1, str1);
diff --git a/net-libs/openslp/files/openslp-2.0.0-cflags.patch b/net-libs/openslp/files/openslp-2.0.0-cflags.patch
deleted file mode 100644
index b77261ee1f6d..000000000000
--- a/net-libs/openslp/files/openslp-2.0.0-cflags.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-diff -ruN openslp-2.0.0.orig/configure.ac openslp-2.0.0/configure.ac
---- openslp-2.0.0.orig/configure.ac 2013-06-08 06:58:54.000000000 +0200
-+++ openslp-2.0.0/configure.ac 2013-07-12 22:17:15.000000000 +0200
-@@ -240,7 +240,6 @@
- OPTFLAGS="-O"
- fi
- fi
--CFLAGS="$CFLAGS $OPTFLAGS"
-
- #
- # Configuration and output
-diff -ruN openslp-2.0.0.orig/etc/Makefile.am openslp-2.0.0/etc/Makefile.am
---- openslp-2.0.0.orig/etc/Makefile.am 2012-11-28 18:07:04.000000000 +0100
-+++ openslp-2.0.0/etc/Makefile.am 2013-07-12 22:28:20.000000000 +0200
-@@ -3,8 +3,8 @@
- dist_sysconf_DATA = slp.conf slp.reg slp.spi
-
- #make sure the slpd log directory is there
--install-data-hook:
-- mkdir -p $(localstatedir)/log
-+#install-data-hook:
-+# mkdir -p $(localstatedir)/log
-
- ##install-data-local:
- ## mkdir -p $(DESTDIR)$(sysconfdir)
diff --git a/net-libs/openslp/files/openslp-2.0.0-namespace.patch b/net-libs/openslp/files/openslp-2.0.0-namespace.patch
deleted file mode 100644
index b5e817877406..000000000000
--- a/net-libs/openslp/files/openslp-2.0.0-namespace.patch
+++ /dev/null
@@ -1,773 +0,0 @@
-# HG changeset patch
-# User John Calcote <john.calcote@gmail.com>
-# Date 1491588156 21600
-# Fri Apr 07 12:02:36 2017 -0600
-# Node ID 51ed69107d096c5b9886954d89e0709975d5aa15
-# Parent c1c294ce953e35f757020b01314cfc49556ccc0c
-BUG#149: cleanup libslp namespace; fix ctype function calls throughout.
-
-diff -ruN openslp-2.0.0.orig/common/slp_compare.c openslp-2.0.0/common/slp_compare.c
---- openslp-2.0.0.orig/common/slp_compare.c 2017-06-10 01:15:33.214875294 +0200
-+++ openslp-2.0.0/common/slp_compare.c 2017-06-10 01:16:39.072878034 +0200
-@@ -83,9 +83,10 @@
- *
- * @internal
- */
--int strncasecmp(const char * s1, const char * s2, size_t len)
-+int slp_strncasecmp(const char * s1, const char * s2, size_t len)
- {
-- while (*s1 && (*s1 == *s2 || tolower(*s1) == tolower(*s2)))
-+ while (*s1 && (*s1 == *s2
-+ || tolower((unsigned char)*s1) == tolower((unsigned char)*s2)))
- {
- len--;
- if (len == 0)
-@@ -93,7 +94,7 @@
- s1++;
- s2++;
- }
-- return len? (int)(*(unsigned char *)s1 - (int)*(unsigned char *)s2): 0;
-+ return len? (unsigned char)*s1 - (unsigned char)*s2: 0;
- }
- # endif
-
-@@ -113,11 +114,12 @@
- *
- * @internal
- */
--int strcasecmp(const char * s1, const char * s2)
-+int slp_strcasecmp(const char * s1, const char * s2)
- {
-- while (*s1 && (*s1 == *s2 || tolower(*s1) == tolower(*s2)))
-+ while (*s1 && (*s1 == *s2
-+ || tolower((unsigned char)*s1) == tolower((unsigned char)*s2)))
- s1++, s2++;
-- return (int)(*(unsigned char *)s1 - (int)*(unsigned char *)s2);
-+ return (unsigned char)*s1 - (unsigned char)*s2;
- }
- # endif
- #endif
-@@ -202,13 +204,13 @@
- char * p = str, * ep = str + len;
- while (p < ep)
- {
-- if (isspace(*p))
-+ if (isspace((unsigned char)*p))
- {
-- char * ws2p = ++p; /* Point ws2p to the second ws char. */
-- while (p < ep && isspace(*p)) /* Scan till we hit a non-ws char. */
-+ char * ws2p = ++p; /* Point ws2p to the second ws char. */
-+ while (p < ep && isspace((unsigned char)*p)) /* Scan till we hit a non-ws char. */
- p++;
-- len -= p - ws2p; /* Reduce the length by extra ws. */
-- memmove(ws2p, p, ep - p); /* Overwrite the extra white space. */
-+ len -= p - ws2p; /* Reduce the length by extra ws. */
-+ memmove(ws2p, p, ep - p); /* Overwrite the extra white space. */
- }
- p++;
- }
-@@ -276,9 +278,9 @@
- char *upd = dststr;
- while (len > 0 && *srcstr)
- {
-- if (isspace(*srcstr))
-+ if (isspace((unsigned char)*srcstr))
- {
-- while (isspace(*srcstr) && len > 0)
-+ while (isspace((unsigned char)*srcstr) && len > 0)
- {
- ++srcstr, --len;
- }
-@@ -311,7 +313,7 @@
- }
- else
- {
-- *upd++ = (char)tolower(*srcstr++);
-+ *upd++ = (char)tolower((unsigned char)*srcstr++);
- --len;
- }
- }
-@@ -340,15 +342,15 @@
- char * cpy1, * cpy2;
-
- /* Remove leading white space. */
-- while (str1len && isspace(*str1))
-+ while (str1len && isspace((unsigned char)*str1))
- str1++, str1len--;
-- while (str2len && isspace(*str2))
-+ while (str2len && isspace((unsigned char)*str2))
- str2++, str2len--;
-
- /* Remove trailing white space. */
-- while (str1len && isspace(str1[str1len - 1]))
-+ while (str1len && isspace((unsigned char)str1[str1len - 1]))
- str1len--;
-- while (str2len && isspace(str2[str2len - 1]))
-+ while (str2len && isspace((unsigned char)str2[str2len - 1]))
- str2len--;
-
- /*A quick check for empty strings before we start xmemduping and xfreeing*/
-diff -ruN openslp-2.0.0.orig/common/slp_compare.h openslp-2.0.0/common/slp_compare.h
---- openslp-2.0.0.orig/common/slp_compare.h 2012-11-28 18:07:04.000000000 +0100
-+++ openslp-2.0.0/common/slp_compare.h 2017-06-10 01:16:39.072878034 +0200
-@@ -52,10 +52,12 @@
-
- #ifndef _WIN32
- # ifndef HAVE_STRNCASECMP
--int strncasecmp(const char * s1, const char * s2, size_t len);
-+int slp_strncasecmp(const char * s1, const char * s2, size_t len);
-+# define strncasecmp slp_strncasecmp
- # endif
- # ifndef HAVE_STRCASECMP
--int strcasecmp(const char * s1, const char * s2);
-+int slp_strcasecmp(const char * s1, const char * s2);
-+# define strcasecmp slp_strcasecmp
- # endif
- #endif
-
-diff -ruN openslp-2.0.0.orig/common/slp_dhcp.c openslp-2.0.0/common/slp_dhcp.c
---- openslp-2.0.0.orig/common/slp_dhcp.c 2012-12-07 01:52:08.000000000 +0100
-+++ openslp-2.0.0/common/slp_dhcp.c 2017-06-10 01:16:39.073878034 +0200
-@@ -405,7 +405,7 @@
- * ENOTCONN (read error), ETIMEDOUT (read timeout), ENOMEM (out of
- * memory), or EINVAL (on parse error).
- */
--int DHCPGetOptionInfo(unsigned char * dhcpOptCodes, int dhcpOptCodeCnt,
-+int slp_DHCPGetOptionInfo(unsigned char * dhcpOptCodes, int dhcpOptCodeCnt,
- DHCPInfoCallBack * dhcpInfoCB, void * context)
- {
- uint32_t xid;
-@@ -539,7 +539,7 @@
- * @return Zero on success, or a non-zero value to stop the caller from
- * continuing to parse the buffer and call this routine.
- */
--int DHCPParseSLPTags(int tag, void * optdata, size_t optdatasz,
-+int slp_DHCPParseSLPTags(int tag, void * optdata, size_t optdatasz,
- void * context)
- {
- size_t cpysz, bufsz, dasize;
-@@ -707,8 +707,8 @@
- ctx.scopelistlen = 0;
- ctx.addrlistlen = 0;
-
-- if ((err = DHCPGetOptionInfo(dhcpOpts, sizeof(dhcpOpts),
-- DHCPParseSLPTags, &ctx)) != 0)
-+ if ((err = slp_DHCPGetOptionInfo(dhcpOpts, sizeof(dhcpOpts),
-+ slp_DHCPParseSLPTags, &ctx)) != 0)
- return FAIL;
-
- printf("ScopeList: [%.*s]\n", ctx.scopelistlen, ctx.scopelist);
-diff -ruN openslp-2.0.0.orig/common/slp_dhcp.h openslp-2.0.0/common/slp_dhcp.h
---- openslp-2.0.0.orig/common/slp_dhcp.h 2012-11-28 18:07:04.000000000 +0100
-+++ openslp-2.0.0/common/slp_dhcp.h 2017-06-10 01:16:39.073878034 +0200
-@@ -131,10 +131,10 @@
- typedef int DHCPInfoCallBack(int tag, void * optdata,
- size_t optdatasz, void * context);
-
--int DHCPGetOptionInfo(unsigned char * dhcpOptCodes, int dhcpOptCodeCnt,
-+int slp_DHCPGetOptionInfo(unsigned char * dhcpOptCodes, int dhcpOptCodeCnt,
- DHCPInfoCallBack * dhcpInfoCB, void * context);
-
--int DHCPParseSLPTags(int tag, void * optdata, size_t optdatasz,
-+int slp_DHCPParseSLPTags(int tag, void * optdata, size_t optdatasz,
- void * context);
-
- /** DHCP interface context structure */
-diff -ruN openslp-2.0.0.orig/common/slp_iface.c openslp-2.0.0/common/slp_iface.c
---- openslp-2.0.0.orig/common/slp_iface.c 2012-12-11 00:31:53.000000000 +0100
-+++ openslp-2.0.0/common/slp_iface.c 2017-06-10 01:16:39.073878034 +0200
-@@ -645,7 +645,7 @@
- *
- * @internal
- */
--int sizeof_ifreq(struct ifreq* ifr)
-+static int sizeof_ifreq(struct ifreq* ifr)
- {
- #ifdef HAVE_SOCKADDR_STORAGE_SS_LEN
- int len = ifr->ifr_addr.sa_len + sizeof(ifr->ifr_name);
-diff -ruN openslp-2.0.0.orig/common/slp_message.c openslp-2.0.0/common/slp_message.c
---- openslp-2.0.0.orig/common/slp_message.c 2012-12-11 00:31:53.000000000 +0100
-+++ openslp-2.0.0/common/slp_message.c 2017-06-10 01:16:39.073878034 +0200
-@@ -58,7 +58,7 @@
- * @return A 16-bit unsigned value in native format; the buffer pointer
- * is moved ahead by 2 bytes on return.
- */
--uint16_t GetUINT16(uint8_t ** cpp)
-+uint16_t slp_GetUINT16(uint8_t ** cpp)
- {
- uint16_t rv = AS_UINT16(*cpp);
- *cpp += 2;
-@@ -72,7 +72,7 @@
- * @return A 32-bit unsigned value in native format; the buffer pointer
- * is moved ahead by 3 bytes on return.
- */
--uint32_t GetUINT24(uint8_t ** cpp)
-+uint32_t slp_GetUINT24(uint8_t ** cpp)
- {
- uint32_t rv = AS_UINT24(*cpp);
- *cpp += 3;
-@@ -86,7 +86,7 @@
- * @return A 32-bit unsigned value in native format; the buffer pointer
- * is moved ahead by 4 bytes on return.
- */
--uint32_t GetUINT32(uint8_t ** cpp)
-+uint32_t slp_GetUINT32(uint8_t ** cpp)
- {
- uint32_t rv = AS_UINT32(*cpp);
- *cpp += 4;
-@@ -106,7 +106,7 @@
- * @p cppstring pointer; the buffer pointer is moved ahead by @p len bytes
- * on return.
- */
--char * GetStrPtr(uint8_t ** cpp, size_t len)
-+char * slp_GetStrPtr(uint8_t ** cpp, size_t len)
- {
- char * sp = (char *)*cpp;
- *cpp += len;
-@@ -120,7 +120,7 @@
- *
- * @note The buffer address is moved ahead by 2 bytes on return.
- */
--void PutUINT16(uint8_t ** cpp, size_t val)
-+void slp_PutUINT16(uint8_t ** cpp, size_t val)
- {
- TO_UINT16(*cpp, val);
- *cpp += 2;
-@@ -133,7 +133,7 @@
- *
- * @note The buffer address is moved ahead by 3 bytes on return.
- */
--void PutUINT24(uint8_t ** cpp, size_t val)
-+void slp_PutUINT24(uint8_t ** cpp, size_t val)
- {
- TO_UINT24(*cpp, val);
- *cpp += 3;
-@@ -146,7 +146,7 @@
- *
- * @note The buffer address is moved ahead by 4 bytes on return.
- */
--void PutUINT32(uint8_t ** cpp, size_t val)
-+void slp_PutUINT32(uint8_t ** cpp, size_t val)
- {
- TO_UINT32(*cpp, val);
- *cpp += 4;
-diff -ruN openslp-2.0.0.orig/common/slp_message.h openslp-2.0.0/common/slp_message.h
---- openslp-2.0.0.orig/common/slp_message.h 2012-12-07 21:13:28.000000000 +0100
-+++ openslp-2.0.0/common/slp_message.h 2017-06-10 01:16:39.073878034 +0200
-@@ -188,14 +188,23 @@
- #define PEEK_LENGTH(p) ((*p == 2) ? AS_UINT24(p + 2) : (*p == 1) ? AS_UINT16(p + 2) : 1)
-
- /* buffer-based wire routines */
--uint16_t GetUINT16(uint8_t ** cpp);
--uint32_t GetUINT24(uint8_t ** cpp);
--uint32_t GetUINT32(uint8_t ** cpp);
--char * GetStrPtr(uint8_t ** cpp, size_t length);
-+uint16_t slp_GetUINT16(uint8_t ** cpp);
-+uint32_t slp_GetUINT24(uint8_t ** cpp);
-+uint32_t slp_GetUINT32(uint8_t ** cpp);
-+char * slp_GetStrPtr(uint8_t ** cpp, size_t length);
-
--void PutUINT16(uint8_t ** cpp, size_t val);
--void PutUINT24(uint8_t ** cpp, size_t val);
--void PutUINT32(uint8_t ** cpp, size_t val);
-+void slp_PutUINT16(uint8_t ** cpp, size_t val);
-+void slp_PutUINT24(uint8_t ** cpp, size_t val);
-+void slp_PutUINT32(uint8_t ** cpp, size_t val);
-+
-+#define GetUINT16 slp_GetUINT16
-+#define GetUINT24 slp_GetUINT24
-+#define GetUINT32 slp_GetUINT32
-+#define GetStrPtr slp_GetStrPtr
-+
-+#define PutUINT16 slp_PutUINT16
-+#define PutUINT24 slp_PutUINT24
-+#define PutUINT32 slp_PutUINT32
-
- /** SLPHeader structure and associated functions */
- typedef struct _SLPHeader
-diff -ruN openslp-2.0.0.orig/common/slp_net.c openslp-2.0.0/common/slp_net.c
---- openslp-2.0.0.orig/common/slp_net.c 2012-12-11 00:31:53.000000000 +0100
-+++ openslp-2.0.0/common/slp_net.c 2017-06-10 01:16:39.073878034 +0200
-@@ -76,18 +76,20 @@
- #endif
-
- /** IPv6 SLP address constants */
--const struct in6_addr in6addr_srvloc_node = IN6ADDR_SRVLOC_NODE_INIT;
--const struct in6_addr in6addr_srvloc_link = IN6ADDR_SRVLOC_LINK_INIT;
--const struct in6_addr in6addr_srvloc_site = IN6ADDR_SRVLOC_SITE_INIT;
--const struct in6_addr in6addr_srvlocda_node = IN6ADDR_SRVLDA_NODE_INIT;
--const struct in6_addr in6addr_srvlocda_link = IN6ADDR_SRVLDA_LINK_INIT;
--const struct in6_addr in6addr_srvlocda_site = IN6ADDR_SRVLDA_SITE_INIT;
--const struct in6_addr in6addr_service_node_mask = IN6ADDR_SVCNOD_MASK_INIT;
--const struct in6_addr in6addr_service_link_mask = IN6ADDR_SVCLNK_MASK_INIT;
--const struct in6_addr in6addr_service_site_mask = IN6ADDR_SVCSIT_MASK_INIT;
--const struct in6_addr slp_in6addr_any = SLP_IN6ADDR_ANY_INIT;
--const struct in6_addr slp_in6addr_loopback = SLP_IN6ADDR_LOOPBACK_INIT;
-+const struct in6_addr in6addr_srvloc_node = IN6ADDR_SRVLOC_NODE_INIT;
-+const struct in6_addr in6addr_srvloc_link = IN6ADDR_SRVLOC_LINK_INIT;
-+const struct in6_addr in6addr_srvloc_site = IN6ADDR_SRVLOC_SITE_INIT;
-
-+const struct in6_addr in6addr_srvlocda_node = IN6ADDR_SRVLDA_NODE_INIT;
-+const struct in6_addr in6addr_srvlocda_link = IN6ADDR_SRVLDA_LINK_INIT;
-+const struct in6_addr in6addr_srvlocda_site = IN6ADDR_SRVLDA_SITE_INIT;
-+
-+const struct in6_addr slp_in6addr_any = SLP_IN6ADDR_ANY_INIT;
-+const struct in6_addr slp_in6addr_loopback = SLP_IN6ADDR_LOOPBACK_INIT;
-+
-+static const struct in6_addr in6addr_service_node_mask = IN6ADDR_SVCNOD_MASK_INIT;
-+static const struct in6_addr in6addr_service_link_mask = IN6ADDR_SVCLNK_MASK_INIT;
-+static const struct in6_addr in6addr_service_site_mask = IN6ADDR_SVCSIT_MASK_INIT;
-
- /** Returns the scope embedded in the IPv6 multicast address.
- *
-diff -ruN openslp-2.0.0.orig/common/slp_net.h openslp-2.0.0/common/slp_net.h
---- openslp-2.0.0.orig/common/slp_net.h 2012-12-11 00:31:53.000000000 +0100
-+++ openslp-2.0.0/common/slp_net.h 2017-06-10 01:16:39.073878034 +0200
-@@ -65,9 +65,6 @@
- extern const struct in6_addr in6addr_srvlocda_node;
- extern const struct in6_addr in6addr_srvlocda_link;
- extern const struct in6_addr in6addr_srvlocda_site;
--extern const struct in6_addr in6addr_service_node_mask;
--extern const struct in6_addr in6addr_service_link_mask;
--/* extern const struct in6_addr in6addr_service_site_mask; */
-
- /** IN6 "Any" and "Loopback" address initializer macros */
- #ifdef _AIX
-diff -ruN openslp-2.0.0.orig/common/slp_network.c openslp-2.0.0/common/slp_network.c
---- openslp-2.0.0.orig/common/slp_network.c 2013-06-08 04:50:38.000000000 +0200
-+++ openslp-2.0.0/common/slp_network.c 2017-06-10 01:16:39.073878034 +0200
-@@ -364,7 +364,7 @@
- * @returns A const pointer to @p dst on success; or NULL on failure,
- * and sets @a errno to EAFNOSUPPORT.
- */
--const char * saddr_ntop(const void * src, char * dst, size_t dstsz)
-+const char * slp_saddr_ntop(const void * src, char * dst, size_t dstsz)
- {
- switch (((const struct sockaddr *)src)->sa_family)
- {
-diff -ruN openslp-2.0.0.orig/common/slp_network.h openslp-2.0.0/common/slp_network.h
---- openslp-2.0.0.orig/common/slp_network.h 2012-11-28 18:07:04.000000000 +0100
-+++ openslp-2.0.0/common/slp_network.h 2017-06-10 01:16:39.073878034 +0200
-@@ -62,7 +62,7 @@
- size_t bufsz, void * peeraddr, struct timeval * timeout);
- int SLPNetworkRecvMessage(sockfd_t sockfd, int socktype, SLPBuffer * buf,
- void * peeraddr, struct timeval * timeout);
--const char * saddr_ntop(const void * src, char * dst, size_t dstsz);
-+const char * slp_saddr_ntop(const void * src, char * dst, size_t dstsz);
-
- void SLPNetworkSetSndRcvBuf(sockfd_t sock);
- /*! @} */
-diff -ruN openslp-2.0.0.orig/common/slp_v1message.c openslp-2.0.0/common/slp_v1message.c
---- openslp-2.0.0.orig/common/slp_v1message.c 2012-12-11 00:31:53.000000000 +0100
-+++ openslp-2.0.0/common/slp_v1message.c 2017-06-10 01:16:39.073878034 +0200
-@@ -275,10 +275,10 @@
- || (tmp = strstr(srvreg->attrlist, "scope")) != 0)
- {
- tmp += 5;
-- while (*tmp && (isspace(*tmp) || *tmp == '='))
-+ while (*tmp && (isspace((unsigned char)*tmp) || *tmp == '='))
- tmp++; /* Find start of scope string. */
- srvreg->scopelist = tmp;
-- while (*tmp && !isspace(*tmp) && *tmp != ')')
-+ while (*tmp && !isspace((unsigned char)*tmp) && *tmp != ')')
- tmp++; /* Find end of scope string. */
- srvreg->scopelistlen = tmp - srvreg->scopelist;
- /** @todo Should we convert to UTF-8 here? */
-diff -ruN openslp-2.0.0.orig/common/slp_xmalloc.c openslp-2.0.0/common/slp_xmalloc.c
---- openslp-2.0.0.orig/common/slp_xmalloc.c 2017-06-10 01:15:33.209875294 +0200
-+++ openslp-2.0.0/common/slp_xmalloc.c 2017-06-10 01:18:31.228882700 +0200
-@@ -106,7 +106,7 @@
- *
- * @return A pointer to the newly allocated memory block.
- */
--void * _xmalloc(const char * file, int line, size_t size)
-+void * slp_xmalloc(const char * file, int line, size_t size)
- {
- xallocation_t * x;
-
-@@ -161,10 +161,10 @@
- *
- * @return A pointer to the newly allocated and cleared memory block.
- */
--void * _xcalloc(const char * file, int line, int numblks, size_t size)
-+void * slp_xcalloc(const char * file, int line, int numblks, size_t size)
- {
- size_t blksz = numblks * size;
-- void * ptr = _xmalloc(file, line, blksz);
-+ void * ptr = slp_xmalloc(file, line, blksz);
- if (ptr)
- memset(ptr, 0, blksz);
- return ptr;
-@@ -183,16 +183,16 @@
- * NULL for @p buf actually allocates a new buffer, passing 0
- * for @p size actually allocates a new buffer.
- */
--void * _xrealloc(const char * file, int line, void * ptr, size_t size)
-+void * slp_xrealloc(const char * file, int line, void * ptr, size_t size)
- {
- xallocation_t * x;
-
- if (!ptr)
-- return _xmalloc(file, line, size);
-+ return slp_xmalloc(file, line, size);
-
- if (!size)
- {
-- _xfree(file, line, ptr);
-+ slp_xfree(file, line, ptr);
- return 0;
- }
-
-@@ -202,11 +202,11 @@
- void * newptr = ptr;
- if (x->size != size)
- {
-- newptr = _xmalloc(file, line, size);
-+ newptr = slp_xmalloc(file, line, size);
- if (newptr == 0)
- return 0;
- memcpy(newptr, ptr, x->size);
-- _xfree(file, line, x);
-+ slp_xfree(file, line, x);
- }
- return newptr;
- }
-@@ -227,10 +227,10 @@
- * @return A pointer to the duplicated string, or NULL on memory
- * allocation failure.
- */
--char * _xstrdup(const char * file, int line, const char * str)
-+char * slp_xstrdup(const char * file, int line, const char * str)
- {
- size_t strsz = strlen(str) + 1;
-- char * ptr = _xmalloc(file, line, strsz);
-+ char * ptr = slp_xmalloc(file, line, strsz);
- if (ptr)
- memcpy(ptr, str, strsz);
- return ptr;
-@@ -246,9 +246,9 @@
- * @return A pointer to the duplicated memory block, or NULL on memory
- * allocation failure.
- */
--void * _xmemdup(const char * file, int line, const void * ptr, size_t size)
-+void * slp_xmemdup(const char * file, int line, const void * ptr, size_t size)
- {
-- void * cpy = _xmalloc(file, line, size);
-+ void * cpy = slp_xmalloc(file, line, size);
- if (cpy)
- memcpy(cpy, ptr, size);
- return cpy;
-@@ -260,7 +260,7 @@
- * @param[in] line - The line number where @e xfree was called.
- * @param[in] ptr - The address of the block to be free'd.
- */
--void _xfree(const char * file, int line, void * ptr)
-+void slp_xfree(const char * file, int line, void * ptr)
- {
- xallocation_t * x;
-
-@@ -292,7 +292,7 @@
- * @return A boolean true (1) on success, or false (0) the log file
- * fails to open.
- */
--int xmalloc_init(const char * filename, size_t freemem)
-+int slp_xmalloc_init(const char * filename, size_t freemem)
- {
- G_xmalloc_fh = fopen(filename, "w");
- if (G_xmalloc_fh == 0)
-@@ -305,7 +305,7 @@
- *
- * @return 0
- */
--int xmalloc_report(void)
-+int slp_xmalloc_report(void)
- {
- xallocation_t * x;
-
-@@ -327,7 +327,7 @@
-
- /** Deinitialize the debug memory allocator.
- */
--void xmalloc_deinit(void)
-+void slp_xmalloc_deinit(void)
- {
- xmalloc_report();
-
-@@ -352,7 +352,7 @@
- * @return A pointer to the duplicated memory block, or NULL on memory
- * allocation failure.
- */
--void * _xmemdup(const void * ptr, size_t size)
-+void * slp_xmemdup(const void * ptr, size_t size)
- {
- void * cpy = malloc(size);
- if (cpy)
-diff -ruN openslp-2.0.0.orig/common/slp_xmalloc.h openslp-2.0.0/common/slp_xmalloc.h
---- openslp-2.0.0.orig/common/slp_xmalloc.h 2012-11-28 18:07:04.000000000 +0100
-+++ openslp-2.0.0/common/slp_xmalloc.h 2017-06-10 01:16:39.073878034 +0200
-@@ -63,34 +63,38 @@
- size_t size;
- } xallocation_t;
-
--void * _xmalloc(const char * file, int line, size_t size);
--void * _xcalloc(const char * file, int line, int numblks, size_t size);
--void * _xrealloc(const char * file, int line, void * ptr, size_t size);
--char * _xstrdup(const char * file, int line, const char * str);
--void * _xmemdup(const char * file, int line, const void * ptr, size_t size);
--void _xfree(const char * file, int line, void * ptr);
--
--int xmalloc_init(const char * filename, size_t freemem);
--int xmalloc_report(void);
--void xmalloc_deinit(void);
--
--#define xmalloc(s) _xmalloc(__FILE__,__LINE__,(s))
--#define xcalloc(n,s) _xcalloc(__FILE__,__LINE__,(n),(s))
--#define xrealloc(p,s) _xrealloc(__FILE__,__LINE__,(p),(s))
--#define xfree(p) _xfree(__FILE__,__LINE__,(p))
--#define xstrdup(p) _xstrdup(__FILE__,__LINE__,(p))
--#define xmemdup(p,s) _xmemdup(__FILE__,__LINE__,(p),(s))
-+void * slp_xmalloc(const char * file, int line, size_t size);
-+void * slp_xcalloc(const char * file, int line, int numblks, size_t size);
-+void * slp_xrealloc(const char * file, int line, void * ptr, size_t size);
-+char * slp_xstrdup(const char * file, int line, const char * str);
-+void * slp_xmemdup(const char * file, int line, const void * ptr, size_t size);
-+void slp_xfree(const char * file, int line, void * ptr);
-+
-+int slp_xmalloc_init(const char * filename, size_t freemem);
-+int slp_xmalloc_report(void);
-+void slp_xmalloc_deinit(void);
-+
-+#define xmalloc(s) slp_xmalloc(__FILE__,__LINE__,(s))
-+#define xcalloc(n,s) slp_xcalloc(__FILE__,__LINE__,(n),(s))
-+#define xrealloc(p,s) slp_xrealloc(__FILE__,__LINE__,(p),(s))
-+#define xfree(p) slp_xfree(__FILE__,__LINE__,(p))
-+#define xstrdup(p) slp_xstrdup(__FILE__,__LINE__,(p))
-+#define xmemdup(p,s) slp_xmemdup(__FILE__,__LINE__,(p),(s))
-+
-+#define xmalloc_init slp_xmalloc_init
-+#define xmalloc_report slp_xmalloc_report
-+#define xmalloc_deinit slp_xmalloc_deinit
-
- #else /* ?DEBUG */
-
--void * _xmemdup(const void * ptr, size_t srclen);
-+void * slp_xmemdup(const void * ptr, size_t srclen);
-
- #define xmalloc malloc
- #define xcalloc calloc
- #define xrealloc realloc
- #define xfree free
- #define xstrdup strdup
--#define xmemdup _xmemdup
-+#define xmemdup slp_xmemdup
-
- #endif /* ?DEBUG */
-
-diff -ruN openslp-2.0.0.orig/libslp/libslp.h openslp-2.0.0/libslp/libslp.h
---- openslp-2.0.0.orig/libslp/libslp.h 2012-11-28 18:07:04.000000000 +0100
-+++ openslp-2.0.0/libslp/libslp.h 2017-06-10 01:16:39.073878034 +0200
-@@ -263,11 +263,15 @@
-
- void KnownDAFreeAll(void);
-
--void PutL16String(uint8_t ** cpp, const char * str, size_t strsz);
--size_t SizeofURLEntry(size_t urllen, size_t urlauthlen);
--void PutURLEntry(uint8_t ** cpp, uint16_t lifetime, const char * url,
-+void slp_PutL16String(uint8_t ** cpp, const char * str, size_t strsz);
-+size_t slp_SizeofURLEntry(size_t urllen, size_t urlauthlen);
-+void slp_PutURLEntry(uint8_t ** cpp, uint16_t lifetime, const char * url,
- size_t urllen, const uint8_t * urlauth, size_t urlauthlen);
-
-+#define PutL16String slp_PutL16String
-+#define SizeofURLEntry slp_SizeofURLEntry
-+#define PutURLEntry slp_PutURLEntry
-+
- int LIBSLPPropertyInit(char const * gconffile);
- void LIBSLPPropertyCleanup();
-
-diff -ruN openslp-2.0.0.orig/libslp/libslp_knownda.c openslp-2.0.0/libslp/libslp_knownda.c
---- openslp-2.0.0.orig/libslp/libslp_knownda.c 2012-12-12 18:38:52.000000000 +0100
-+++ openslp-2.0.0/libslp/libslp_knownda.c 2017-06-10 01:16:39.074878034 +0200
-@@ -520,7 +520,7 @@
- *ctx.scopelist = 0;
- ctx.addrlistlen = 0;
-
-- DHCPGetOptionInfo(dhcpOpts, sizeof(dhcpOpts), DHCPParseSLPTags, &ctx);
-+ slp_DHCPGetOptionInfo(dhcpOpts, sizeof(dhcpOpts), slp_DHCPParseSLPTags, &ctx);
-
- if (!*ctx.scopelist)
- {
-diff -ruN openslp-2.0.0.orig/libslp/libslp_network.c openslp-2.0.0/libslp/libslp_network.c
---- openslp-2.0.0.orig/libslp/libslp_network.c 2013-06-08 04:50:38.000000000 +0200
-+++ openslp-2.0.0/libslp/libslp_network.c 2017-06-10 01:16:39.074878034 +0200
-@@ -142,7 +142,7 @@
- *
- * @internal
- */
--void timeval_subtract(struct timeval *lhs, struct timeval *rhs)
-+static void timeval_subtract(struct timeval *lhs, struct timeval *rhs)
- {
- lhs->tv_sec -= rhs->tv_sec;
- lhs->tv_usec -= rhs->tv_usec;
-@@ -162,7 +162,7 @@
- *
- * @internal
- */
--void timeval_add(struct timeval *lhs, struct timeval *rhs)
-+static void timeval_add(struct timeval *lhs, struct timeval *rhs)
- {
- lhs->tv_sec += rhs->tv_sec;
- lhs->tv_usec += rhs->tv_usec;
-@@ -183,7 +183,7 @@
- *
- * @return the size
- */
--size_t CalcBufferSize(int v1, char buftype, size_t langsize, size_t prlistlen, size_t bufsize)
-+static size_t CalcBufferSize(int v1, char buftype, size_t langsize, size_t prlistlen, size_t bufsize)
- {
- size_t size = 0;
-
-diff -ruN openslp-2.0.0.orig/libslp/libslp_parse.c openslp-2.0.0/libslp/libslp_parse.c
---- openslp-2.0.0.orig/libslp/libslp_parse.c 2012-12-11 00:31:53.000000000 +0100
-+++ openslp-2.0.0/libslp/libslp_parse.c 2017-06-10 01:16:39.074878034 +0200
-@@ -102,10 +102,10 @@
- * next buffer position after the URL Entry written on exit.
- *
- * @remarks Currently OpenSLP only handles a single authentication
-- * block. To handle more than this, PutURLEntry would have to take
-+ * block. To handle more than this, slp_PutURLEntry would have to take
- * arrays of @p urlauth and @p urlauthlen values.
- */
--void PutURLEntry(uint8_t ** cpp, uint16_t lifetime, const char * url,
-+void slp_PutURLEntry(uint8_t ** cpp, uint16_t lifetime, const char * url,
- size_t urllen, const uint8_t * urlauth, size_t urlauthlen)
- {
- uint8_t * curpos = *cpp;
-diff -ruN openslp-2.0.0.orig/libslpattr/libslpattr.c openslp-2.0.0/libslpattr/libslpattr.c
---- openslp-2.0.0.orig/libslpattr/libslpattr.c 2012-12-11 00:31:53.000000000 +0100
-+++ openslp-2.0.0/libslpattr/libslpattr.c 2017-06-10 01:16:39.074878034 +0200
-@@ -134,8 +134,8 @@
- */
- static char unescape(char d1, char d2)
- {
-- SLP_ASSERT(isxdigit((int) d1));
-- SLP_ASSERT(isxdigit((int) d2));
-+ SLP_ASSERT(isxdigit((unsigned char)d1));
-+ SLP_ASSERT(isxdigit((unsigned char)d2));
-
- if ((d1 >= 'A') && (d1 <= 'F'))
- d1 = d1 - 'A' + 0x0A;
-@@ -184,8 +184,8 @@
- /*** Check that the characters are legal, and that the value has
- * not been truncated.
- ***/
-- if ((i + 2 < len) && isxdigit((int) src[i + 1]) && isxdigit((int)
-- src[i + 2]))
-+ if ((i + 2 < len) && isxdigit((unsigned char)src[i + 1])
-+ && isxdigit((unsigned char)src[i + 2]))
- {
- *write = unescape(src[i + 1], src[i + 2]);
- i += 2;
-@@ -2049,14 +2049,14 @@
-
-
- /***** Check integer *****/
-- if (*val == '-' || isdigit((int) * val))
-+ if (*val == '-' || isdigit((unsigned char)*val))
- {
- /*** Verify. ***/
- SLPBoolean is_int = SLP_TRUE; /* Flag true if the attr is an int. */
- for (i = 1; i < len; i++)
- {
- /* We start at 1 since first char has already been checked. */
-- if (!isdigit((int) val[i]))
-+ if (!isdigit((unsigned char)val[i]))
- {
- is_int = SLP_FALSE;
- break;
-diff -ruN openslp-2.0.0.orig/slpd/slpd_knownda.c openslp-2.0.0/slpd/slpd_knownda.c
---- openslp-2.0.0.orig/slpd/slpd_knownda.c 2012-12-11 00:31:53.000000000 +0100
-+++ openslp-2.0.0/slpd/slpd_knownda.c 2017-06-10 01:16:39.074878034 +0200
-@@ -488,7 +488,7 @@
- *ctx.scopelist = 0;
- ctx.addrlistlen = 0;
-
-- DHCPGetOptionInfo(dhcpOpts, sizeof(dhcpOpts), DHCPParseSLPTags, &ctx);
-+ slp_DHCPGetOptionInfo(dhcpOpts, sizeof(dhcpOpts), slp_DHCPParseSLPTags, &ctx);
-
- alp = ctx.addrlist;
- while (ctx.addrlistlen >= 4)
-diff -ruN openslp-2.0.0.orig/slpd/slpd_main.c openslp-2.0.0/slpd/slpd_main.c
---- openslp-2.0.0.orig/slpd/slpd_main.c 2012-12-11 00:31:53.000000000 +0100
-+++ openslp-2.0.0/slpd/slpd_main.c 2017-06-10 01:16:39.074878034 +0200
-@@ -358,10 +358,11 @@
- if (fd)
- {
- memset(pidstr,0,14);
-- (void)fread(pidstr,13,1,fd);
-- pid = atoi(pidstr);
-- if (pid && kill(pid, 0) == 0)
-- return -1; /* we are already running */
-+ if (fread(pidstr,13,1,fd) > 0) {
-+ pid = atoi(pidstr);
-+ if (pid && kill(pid, 0) == 0)
-+ return -1; /* we are already running */
-+ }
- fclose(fd);
- }
- return 0;
-@@ -449,7 +450,8 @@
- int i;
-
- /* change directory to root */
-- (void)chdir("/");
-+ if (chdir("/") != 0)
-+ ; /* TODO: ... */
-
- /* close all open file handles */
- for (i = 0; i < 8192; i++)
-diff -ruN openslp-2.0.0.orig/slpd/slpd_predicate.c openslp-2.0.0/slpd/slpd_predicate.c
---- openslp-2.0.0.orig/slpd/slpd_predicate.c 2012-12-11 00:31:53.000000000 +0100
-+++ openslp-2.0.0/slpd/slpd_predicate.c 2017-06-10 01:16:39.075878034 +0200
-@@ -161,7 +161,7 @@
- /* Verify escape sequences. */
- if (seq_pos == 1 || seq_pos == 2)
- {
-- if (!isxdigit((int) escaped[i]))
-+ if (!isxdigit((unsigned char)escaped[i]))
- return 0;
-
- if (seq_pos == 2)
-@@ -198,7 +198,7 @@
- */
- static int unescape_check(char d1, char d2, char * val)
- {
-- if (!isxdigit((int) d1) || !isxdigit((int) d2))
-+ if (!isxdigit((unsigned char)d1) || !isxdigit((unsigned char)d2))
- return 0;
-
- if ((d1 >= 'A') && (d1 <= 'F'))
-@@ -285,10 +285,10 @@
-
- if (unesc != verbatim[ver_i]) /* quick check for equality*/
- {
-- if (!isascii(unesc) /* case insensitive check */
-- || !isalpha(unesc)
-- || !isalpha(verbatim[ver_i])
-- || tolower(unesc) != tolower(verbatim[ver_i]))
-+ if (!isascii((unsigned char)unesc) /* case insensitive check */
-+ || !isalpha((unsigned char)unesc)
-+ || !isalpha((unsigned char)verbatim[ver_i])
-+ || tolower((unsigned char)unesc) != tolower((unsigned char)verbatim[ver_i]))
- return FR_EVAL_FALSE;
- }
-
-@@ -866,7 +866,7 @@
- int i;
-
- for (i = 0; str[i] != 0; i++)
-- if (!((!isdigit((int) str[i])) || str[i] == '-'))
-+ if (!((!isdigit((unsigned char)str[i])) || str[i] == '-'))
- return 0;
-
- return 1;
diff --git a/net-libs/openslp/files/slpd-init b/net-libs/openslp/files/slpd-init
deleted file mode 100644
index de7f5af3131e..000000000000
--- a/net-libs/openslp/files/slpd-init
+++ /dev/null
@@ -1,88 +0,0 @@
-#!/sbin/openrc-run
-# Copyright 1999-2012 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-
-depend() {
- need net
-}
-
-#
-# Does nothing if a route exists that supports multicast traffic.
-# If no routes supporting multicast traffic exists, the function
-# tries to add one. A 0 is returned on success and a 1 on failure.
-# One parameter must be passed in. This variable determins verbosity.
-# If parameter is non-zero debugging will appear.
-#
-multicast_route_set() {
- PING_OPTIONS_1='-c1 -w1'
- PING_OPTIONS_2='-c1 -i1'
- MULTICAST_ADDRESS='239.255.255.253'
- TMP_FILE=/tmp/route.check
- PING_ERROR_NO_ROUTE='unreachable'
-
- MSG_FAILED_TO_FIND='Failed to Detect Multicast Route'
- MSG_SUCCESS_ON_FIND='Multicast Route Enabled'
- MSG_ADDING_ROUTE='Attempting to Add Multicast Route ...'
- MSG_FAILED_TO_ADD=' FAILED - Route NOT Added.'
- MSG_SUCCES_ON_ADD=' SUCCESS - Route Added.'
-
- CMD_GET_INTERFACE="netstat -i | awk 'BEGIN{}(NR>2)&&(!/^lo*/){print \$1;exit}'"
- CMD_ADD_ROUTE="route add -net 224.0.0.0 netmask 240.0.0.0"
-
- ping $PING_OPTIONS_1 $MULTICAST_ADDRESS 2> $TMP_FILE 1> /dev/null
- if [ $? = 2 ]; then
- ping $PING_OPTIONS_2 $MULTICAST_ADDRESS 2> $TMP_FILE 1> /dev/null
- fi
-
- grep $PING_ERROR_NO_ROUTE $TMP_FILE > /dev/null 2>&1
- err_unreachable_found=$?
-
- #If errors, add route. Otherwise, do nothing
- if [ -s $TMP_FILE ] && [ $err_unreachable_found = 0 ]; then
-
- if [ $1 != 0 ]; then
- echo $MSG_FAILED_TO_FIND
- echo $MSG_ADDING_ROUTE
- fi
-
- $CMD_ADD_ROUTE `eval $CMD_GET_INTERFACE` > /dev/null 2>&1
- retval=$?
- if [ $1 != 0 ]; then
-
- if [ $retval = 0 ]; then
- echo $MSG_SUCCES_ON_ADD
- else
- echo $MSG_FAILED_TO_ADD
- fi
- fi
- else
- if [ $1 != 0 ]; then
- echo -n $MSG_SUCCESS_ON_FIND
- fi
- retval=0
- fi
-
- rm -f $TMP_FILE # Clean up
- return $retval
-}
-
-checkconfig() {
- multicast_route_set 0
- if [ $? -ne 0 ]; then
- eerror "No route available for multicast traffic!"
- return 1
- fi
-}
-
-start() {
- checkconfig || return 1
- ebegin "Starting slpd"
- start-stop-daemon --start --quiet --exec /usr/sbin/slpd --pidfile /var/run/slpd.pid
- eend $?
-}
-
-stop() {
- ebegin "Stopping slpd"
- start-stop-daemon --stop --quiet --pidfile /var/run/slpd.pid
- eend $?
-}
diff --git a/net-libs/openslp/files/slpd.service b/net-libs/openslp/files/slpd.service
deleted file mode 100644
index ab5c02f3b773..000000000000
--- a/net-libs/openslp/files/slpd.service
+++ /dev/null
@@ -1,10 +0,0 @@
-[Unit]
-Description=Service Location Protocol
-After=network-online.target
-
-[Service]
-ExecStart=/usr/sbin/slpd -l /var/log/slpd.log -d
-ExecReload=/bin/kill -HUP $MAINPID
-
-[Install]
-WantedBy=network.target
diff --git a/net-libs/openslp/metadata.xml b/net-libs/openslp/metadata.xml
deleted file mode 100644
index c01f3945d893..000000000000
--- a/net-libs/openslp/metadata.xml
+++ /dev/null
@@ -1,11 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
-<pkgmetadata>
- <maintainer type="project">
- <email>printing@gentoo.org</email>
- <name>Gentoo Printing Project</name>
- </maintainer>
- <upstream>
- <remote-id type="sourceforge">openslp</remote-id>
- </upstream>
-</pkgmetadata>
diff --git a/net-libs/openslp/openslp-1.2.1-r3.ebuild b/net-libs/openslp/openslp-1.2.1-r3.ebuild
deleted file mode 100644
index db091b2a3ce6..000000000000
--- a/net-libs/openslp/openslp-1.2.1-r3.ebuild
+++ /dev/null
@@ -1,43 +0,0 @@
-# Copyright 1999-2018 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=0
-
-inherit eutils autotools systemd
-
-DESCRIPTION="An open-source implementation of Service Location Protocol"
-HOMEPAGE="http://www.openslp.org/"
-SRC_URI="mirror://sourceforge/openslp/${P}.tar.gz"
-
-LICENSE="BSD GPL-2"
-SLOT="0"
-KEYWORDS="alpha amd64 arm hppa ia64 ~m68k ~mips ppc ppc64 ~s390 ~sh sparc x86 ~amd64-linux ~x86-linux"
-IUSE=""
-RESTRICT="test"
-
-DEPEND="dev-libs/openssl"
-RDEPEND="${DEPEND}"
-
-src_unpack() {
- unpack ${A}
- cd "${S}"
-
- epatch "${FILESDIR}"/${P}-fbsd.patch
- epatch "${FILESDIR}"/${P}-fixoverflow.patch
- epatch "${FILESDIR}"/${P}-cflags.patch
- eautoreconf
-}
-
-src_compile() {
- econf || die
- emake -j1 || die "make failed"
-}
-
-src_install() {
- make DESTDIR="${D}" install || die "make install failed"
- dodoc AUTHORS FAQ ChangeLog NEWS README* THANKS
- rm -rf "${D}"/usr/doc
- dohtml -r .
- newinitd "${FILESDIR}"/slpd-init slpd
- systemd_dounit "${FILESDIR}"/slpd.service
-}
diff --git a/net-libs/openslp/openslp-2.0.0-r4.ebuild b/net-libs/openslp/openslp-2.0.0-r4.ebuild
deleted file mode 100644
index cadea63285dd..000000000000
--- a/net-libs/openslp/openslp-2.0.0-r4.ebuild
+++ /dev/null
@@ -1,43 +0,0 @@
-# Copyright 1999-2018 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=6
-
-inherit autotools systemd
-
-DESCRIPTION="An open-source implementation of Service Location Protocol"
-HOMEPAGE="http://www.openslp.org/"
-SRC_URI="mirror://sourceforge/openslp/${P}.tar.gz"
-
-LICENSE="BSD GPL-2"
-SLOT="0"
-KEYWORDS="alpha amd64 arm hppa ia64 ~m68k ~mips ppc ppc64 s390 ~sh sparc x86 ~amd64-linux ~x86-linux"
-IUSE="libressl"
-RESTRICT="test"
-
-DEPEND="
- !libressl? ( dev-libs/openssl:0= )
- libressl? ( dev-libs/libressl:0= )
-"
-RDEPEND="${DEPEND}"
-
-PATCHES=(
- "${FILESDIR}"/${PN}-2.0.0-cflags.patch
- "${FILESDIR}"/${PN}-2.0.0-CVE-2016-4912.patch
- "${FILESDIR}"/${PN}-2.0.0-CVE-2012-4428.patch
- "${FILESDIR}"/${PN}-2.0.0-CVE-2016-7567.patch
-)
-
-src_prepare() {
- default
- eautoreconf
-}
-
-src_install() {
- make DESTDIR="${D}" install || die "make install failed"
- dodoc AUTHORS FAQ ChangeLog NEWS README* THANKS
- rm -rfv "${D}"/usr/doc
- dohtml -r .
- newinitd "${FILESDIR}"/slpd-init slpd
- systemd_dounit "${FILESDIR}"/slpd.service
-}
diff --git a/net-libs/openslp/openslp-2.0.0-r5.ebuild b/net-libs/openslp/openslp-2.0.0-r5.ebuild
deleted file mode 100644
index c9a5e673bd4c..000000000000
--- a/net-libs/openslp/openslp-2.0.0-r5.ebuild
+++ /dev/null
@@ -1,44 +0,0 @@
-# Copyright 1999-2019 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=6
-
-inherit autotools systemd
-
-DESCRIPTION="An open-source implementation of Service Location Protocol"
-HOMEPAGE="http://www.openslp.org/"
-SRC_URI="mirror://sourceforge/openslp/${P}.tar.gz"
-
-LICENSE="BSD GPL-2"
-SLOT="0"
-KEYWORDS="~alpha ~amd64 ~arm arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sh ~sparc ~x86 ~amd64-linux ~x86-linux"
-IUSE="libressl"
-RESTRICT="test"
-
-DEPEND="
- !libressl? ( dev-libs/openssl:0= )
- libressl? ( dev-libs/libressl:0= )
-"
-RDEPEND="${DEPEND}"
-
-PATCHES=(
- "${FILESDIR}"/${PN}-2.0.0-cflags.patch
- "${FILESDIR}"/${PN}-2.0.0-CVE-2016-4912.patch
- "${FILESDIR}"/${PN}-2.0.0-CVE-2012-4428.patch
- "${FILESDIR}"/${PN}-2.0.0-CVE-2016-7567.patch
- "${FILESDIR}"/${PN}-2.0.0-namespace.patch
-)
-
-src_prepare() {
- default
- eautoreconf
-}
-
-src_install() {
- make DESTDIR="${D}" install || die "make install failed"
- dodoc AUTHORS FAQ ChangeLog NEWS README* THANKS
- rm -rfv "${D}"/usr/doc
- dohtml -r .
- newinitd "${FILESDIR}"/slpd-init slpd
- systemd_dounit "${FILESDIR}"/slpd.service
-}