From 6896eeefe630661d68b26377ee8fbd5e41a37f38 Mon Sep 17 00:00:00 2001 From: Til Kaiser Date: Sat, 6 Jun 2026 15:48:25 +0200 Subject: [PATCH] watchcat: fix optional mmifacename handling restart_iface treated an unset mmifacename as the literal string "null", which made watchcat take the ModemManager restart path unless users explicitly configured mmifacename as an empty string. Default mmifacename to empty instead. Signed-off-by: Til Kaiser --- utils/watchcat/Makefile | 2 +- utils/watchcat/files/watchcat.init | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/utils/watchcat/Makefile b/utils/watchcat/Makefile index b66a237ac50677..88fb0bfc7d44b8 100644 --- a/utils/watchcat/Makefile +++ b/utils/watchcat/Makefile @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=watchcat PKG_VERSION:=1 -PKG_RELEASE:=22 +PKG_RELEASE:=23 PKG_MAINTAINER:=Roger D PKG_LICENSE:=GPL-2.0 diff --git a/utils/watchcat/files/watchcat.init b/utils/watchcat/files/watchcat.init index 9bfc68d0e3bab3..1883b01154959d 100644 --- a/utils/watchcat/files/watchcat.init +++ b/utils/watchcat/files/watchcat.init @@ -39,7 +39,7 @@ config_watchcat() { config_get forcedelay "$1" forcedelay "60" config_get pingsize "$1" pingsize "standard" config_get interface "$1" interface - config_get mmifacename "$1" mmifacename "null" + config_get mmifacename "$1" mmifacename config_get_bool unlockbands "$1" unlockbands "0" config_get addressfamily "$1" addressfamily "any" config_get script "$1" script @@ -73,7 +73,7 @@ config_watchcat() { append_string "warn" "pingperiod cannot be a negative value." "; " fi - if [ "$mmifacename" != "null" ] && [ "$period" -lt 30 ]; then + if [ -n "$mmifacename" ] && [ "$period" -lt 30 ]; then append_string "error" "Check interval is less than 30s. For robust operation with ModemManager modem interfaces it is recommended to set the period to at least 30s." fi fi