From ca90c388045b4498fe32e706bd1bdcf7a6ac8e17 Mon Sep 17 00:00:00 2001 From: Paul Wise Date: Fri, 7 Apr 2017 08:18:17 +0800 Subject: Support zero delay for the various APT::Periodic activities [squashed:] apt.systemd.daily: check_stamp: check for 'always' before numerical values Prevents a crash when the configuration actually uses 'always': apt.systemd.daily: 402: [: Illegal number: always --- debian/apt.systemd.daily | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/debian/apt.systemd.daily b/debian/apt.systemd.daily index 49af931bd..efd921ea9 100755 --- a/debian/apt.systemd.daily +++ b/debian/apt.systemd.daily @@ -78,6 +78,12 @@ check_stamp() stamp="$1" interval="$2" + if [ $interval = always ]; then + debug_echo "check_stamp: ignoring time stamp file, interval set to always" + # treat as enough time has passed + return 0 + fi + if [ $interval -eq 0 ]; then debug_echo "check_stamp: interval=0" # treat as no time has passed -- cgit v1.2.3