adblock: update 4.4.2-2
authorDirk Brenken <[email protected]>
Sat, 31 May 2025 21:06:33 +0000 (23:06 +0200)
committerDirk Brenken <[email protected]>
Sat, 31 May 2025 21:07:03 +0000 (23:07 +0200)
* sanitize the json reporting output

Signed-off-by: Dirk Brenken <[email protected]>
net/adblock/Makefile
net/adblock/files/adblock.sh

index c1512ab3f60b9ab305c199c2835d04414f503183..35945dbebf5ac86acbd21b1dceb2e0f300c3e624 100644 (file)
@@ -7,7 +7,7 @@ include $(TOPDIR)/rules.mk
 
 PKG_NAME:=adblock
 PKG_VERSION:=4.4.2
-PKG_RELEASE:=1
+PKG_RELEASE:=2
 PKG_LICENSE:=GPL-3.0-or-later
 PKG_MAINTAINER:=Dirk Brenken <[email protected]>
 
index e636bcdf1dca267797349549fe3ceb8093d97355..134844b229d3742f550cfb7bc8974d7f5a0310b6 100755 (executable)
@@ -1544,11 +1544,11 @@ f_report() {
                        ;;
                "json")
                        if [ "${adb_map}" = "1" ]; then
-                               jsn="$("${adb_catcmd}" ${report_jsn} ${map_jsn})"
-                               printf "[%s]]\n" "${jsn}"
+                               jsn="$("${adb_catcmd}" ${report_jsn} ${map_jsn} 2>/dev/null)"
+                               [ -n "${jsn}" ] && printf "[%s]]\n" "${jsn}"
                        else
-                               jsn="$("${adb_catcmd}" ${report_jsn})"
-                               printf "[%s]\n" "${jsn}"
+                               jsn="$("${adb_catcmd}" ${report_jsn} 2>/dev/null)"
+                               [ -n "${jsn}" ] && printf "[%s]\n" "${jsn}"
                        fi
                        ;;
                "mail")