From: Dirk Brenken Date: Mon, 20 Feb 2023 18:17:16 +0000 (+0100) Subject: banip: update 0.8.0-2 X-Git-Url: http://git.99rst.org/?a=commitdiff_plain;h=b50383e4d9daa313d55dcc42c19ce0b4d3725aea;p=openwrt-packages.git banip: update 0.8.0-2 * fix a potential race condition during initial startup (after flash) which leads to a "disabled" service Signed-off-by: Dirk Brenken --- diff --git a/net/banip/Makefile b/net/banip/Makefile index a816ec858..5070d8aa6 100644 --- a/net/banip/Makefile +++ b/net/banip/Makefile @@ -8,7 +8,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=banip PKG_VERSION:=0.8.0 -PKG_RELEASE:=1 +PKG_RELEASE:=2 PKG_LICENSE:=GPL-3.0-or-later PKG_MAINTAINER:=Dirk Brenken diff --git a/net/banip/files/banip.init b/net/banip/files/banip.init index ab126f230..61639acfb 100755 --- a/net/banip/files/banip.init +++ b/net/banip/files/banip.init @@ -18,8 +18,8 @@ ban_funlib="/usr/lib/banip-functions.sh" ban_pidfile="/var/run/banip.pid" ban_lock="/var/run/banip.lock" -[ ! -r "${ban_funlib}" ] && exit 1 [ "${action}" = "stop" ] && ! /etc/init.d/banip running && exit 0 +[ ! -r "${ban_funlib}" ] && { [ "${action}" = "start" ] || [ "${action}" = "restart" ] || [ "${action}" = "reload" ] || [ "${action}" = "stop" ] || [ "${action}" = "report" ] || [ "${action}" = "search" ] || [ "${action}" = "status" ]; } && exit 1 [ -d "${ban_lock}" ] && { [ "${action}" = "start" ] || [ "${action}" = "restart" ] || [ "${action}" = "reload" ]; } && exit 1 [ ! -d "${ban_lock}" ] && { [ "${action}" = "start" ] || [ "${action}" = "restart" ] || [ "${action}" = "reload" ]; } && mkdir -p "${ban_lock}"