miniupnpc: update to 2.3.3
authorAlexandru Ardelean <redacted>
Wed, 22 Apr 2026 09:12:19 +0000 (12:12 +0300)
committerAlexandru Ardelean <redacted>
Thu, 14 May 2026 12:39:33 +0000 (15:39 +0300)
Changes since 2.2.8:
- Fix crash related to FD_SET and socket timeout handling
- Fix build_absolute_url when if_indextoname() returns NULL
- Add support for C23 and glibc 2.43 string function signatures
- Improve poll() usage and C++ compiler compatibility

Signed-off-by: Alexandru Ardelean <redacted>
net/miniupnpc/Makefile
net/miniupnpc/patches/200-miniupnpc_desc.patch
net/miniupnpc/test.sh [new file with mode: 0644]

index 0f2f38f4d7c762a866050a4366c8bf5d60245bbd..ae283384db1327b65f85dc7e02b03a2d87bf3d68 100644 (file)
@@ -8,12 +8,12 @@
 include $(TOPDIR)/rules.mk
 
 PKG_NAME:=miniupnpc
-PKG_VERSION:=2.2.8
+PKG_VERSION:=2.3.3
 PKG_RELEASE:=1
 
 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
 PKG_SOURCE_URL:=https://miniupnp.tuxfamily.org/files
-PKG_HASH:=05b929679091b9921b6b6c1f25e39e4c8d1f4d46c8feb55a412aa697aee03a93
+PKG_HASH:=d52a0afa614ad6c088cc9ddff1ae7d29c8c595ac5fdd321170a05f41e634bd1a
 
 PKG_MAINTAINER:=Alexandru Ardelean <ardeleanalex@gmail.com>
 PKG_LICENSE:=BSD-3-Clause
index 681fc5ed396a676b840203d6356fbde7bd7267c1..7087928aba3edb13c86fe67f91b8eec2844250d7 100644 (file)
@@ -1,11 +1,20 @@
 --- a/src/upnpcommands.c
 +++ b/src/upnpcommands.c
-@@ -371,7 +371,7 @@ UPNP_AddPortMapping(const char * control
-       AddPortMappingArgs[5].elt = "NewEnabled";
-       AddPortMappingArgs[5].val = "1";
-       AddPortMappingArgs[6].elt = "NewPortMappingDescription";
--      AddPortMappingArgs[6].val = desc?desc:"libminiupnpc";
-+      AddPortMappingArgs[6].val = desc?desc:"miniupnpc";
-       AddPortMappingArgs[7].elt = "NewLeaseDuration";
-       AddPortMappingArgs[7].val = leaseDuration?leaseDuration:"0";
-       buffer = simpleUPnPcommand(-1, controlURL, servicetype,
+@@ -357,7 +357,7 @@ UPNP_AddPortMapping(const char * control
+               {"NewInternalPort", inPort},
+               {"NewInternalClient", inClient},
+               {"NewEnabled", "1"},
+-              {"NewPortMappingDescription", desc?desc:"libminiupnpc"},
++              {"NewPortMappingDescription", desc?desc:"miniupnpc"},
+               {"NewLeaseDuration", leaseDuration?leaseDuration:"0"},
+               {NULL, NULL}
+       };
+@@ -411,7 +411,7 @@ UPNP_AddAnyPortMapping(const char * cont
+               {"NewInternalPort", inPort},
+               {"NewInternalClient", inClient},
+               {"NewEnabled", "1"},
+-              {"NewPortMappingDescription", desc?desc:"libminiupnpc"},
++              {"NewPortMappingDescription", desc?desc:"miniupnpc"},
+               {"NewLeaseDuration", leaseDuration?leaseDuration:"0"},
+               {NULL, NULL}
+       };
diff --git a/net/miniupnpc/test.sh b/net/miniupnpc/test.sh
new file mode 100644 (file)
index 0000000..78c5048
--- /dev/null
@@ -0,0 +1,16 @@
+#!/bin/sh
+
+case "$1" in
+libminiupnpc)
+       # Verify the shared library is installed
+       ls /usr/lib/libminiupnpc.so.* > /dev/null
+       ;;
+miniupnpc)
+       # upnpc without args exits non-zero but prints usage including port
+       # redirection operations and the discover (-l) option
+       upnpc 2>&1 | grep -qi "Add port redirection\|port redirection\|upnp"
+       ;;
+*)
+       exit 0
+       ;;
+esac
git clone https://git.99rst.org/PROJECT