From adbce12126ccc58016af69d541bafad5c8bde631 Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Tue, 14 Jul 2009 11:24:19 +0200 Subject: [PATCH] * debian/apt.cron.daily: - if the timestamp is too far in the future, delete it (LP: #135262) --- debian/apt.cron.daily | 7 +++++++ debian/changelog | 4 ++++ 2 files changed, 11 insertions(+) diff --git a/debian/apt.cron.daily b/debian/apt.cron.daily index 7f2978568..3c440307c 100644 --- a/debian/apt.cron.daily +++ b/debian/apt.cron.daily @@ -76,6 +76,13 @@ check_stamp() #echo "stampfile: $1" #echo "interval=$interval, now=$now, stamp=$stamp, delta=$delta" + # remove timestamps a day (or more) in the future and force re-check + if [ $stamp -gt $(($now+86400)) ]; then + echo "WARNING: file $stamp_file has a timestamp in the future: $stamp" + rm -f "$stamp_file" + return 0 + fi + if [ $delta -ge $interval ]; then return 0 fi diff --git a/debian/changelog b/debian/changelog index d6e6a5997..498c6710c 100644 --- a/debian/changelog +++ b/debian/changelog @@ -7,6 +7,10 @@ apt (0.7.21ubuntu2~ppa1) karmic; urgency=low * methods/http.cc: - ignore SIGPIPE, we deal with EPIPE from write in HttpMethod::ServerDie() (LP: #385144) + * debian/apt.cron.daily: + - if the timestamp is too far in the future, delete it + (LP: #135262) + -- Michael Vogt Thu, 02 Jul 2009 14:11:35 +0200 -- 2.50.0