From fe736b2f8c415e6d590931f1f1f504e1d18c579b Mon Sep 17 00:00:00 2001 From: Dirk Brenken Date: Mon, 19 Feb 2024 14:54:08 +0100 Subject: [PATCH] openvpn: fix start_path_instance function Check the conffile existance (with .conf extension), before calling the function 'start_path_instance'. This fixes errors with non-existing and wrong spelling instances. Signed-off-by: Dirk Brenken - Update commit description Signed-off-by: Florian Eckert --- net/openvpn/Makefile | 2 +- net/openvpn/files/openvpn.init | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/net/openvpn/Makefile b/net/openvpn/Makefile index 365fed6c7..8d35c7477 100644 --- a/net/openvpn/Makefile +++ b/net/openvpn/Makefile @@ -10,7 +10,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=openvpn PKG_VERSION:=2.6.8 -PKG_RELEASE:=5 +PKG_RELEASE:=6 PKG_SOURCE_URL:=\ https://build.openvpn.net/downloads/releases/ \ diff --git a/net/openvpn/files/openvpn.init b/net/openvpn/files/openvpn.init index 89d25b59c..5c1beb0e3 100644 --- a/net/openvpn/files/openvpn.init +++ b/net/openvpn/files/openvpn.init @@ -281,7 +281,7 @@ start_service() { if [ -n "$instance" ]; then if [ "$instance_found" -gt 0 ]; then start_uci_instance "$instance" - else + elif [ -f "${PATH_INSTANCE_DIR}/${instance}.conf" ]; then start_path_instance "$instance" fi else @@ -299,4 +299,3 @@ start_service() { service_triggers() { procd_add_reload_trigger openvpn } -