Przeglądaj źródła

Make cron script quiet if cache is locked. Closes: #459344

Otavio Salvador 18 lat temu
rodzic
commit
626a8c601b
2 zmienionych plików z 5 dodań i 2 usunięć
  1. 3 2
      debian/apt.cron.daily
  2. 2 0
      debian/changelog

+ 3 - 2
debian/apt.cron.daily

@@ -193,9 +193,10 @@ if which on_ac_power >/dev/null; then
 fi
 
 # check if we can lock the cache and if the cache is clean
+# There's a reasonable chance that someone is already running an apt
+# frontend that has locked the cache, so exit quietly if it is locked.
 if ! apt-get check -q -q 2>/dev/null; then
-    echo "$0: could not lock the APT cache"
-    exit 1
+    exit 0
 fi
 
 # sleep random amount of time

+ 2 - 0
debian/changelog

@@ -2,6 +2,8 @@ apt (0.7.13) UNRELEASED; urgency=low
 
   * Add missing build-depends back from build-depends-indep field.
     Closes: #478231
+  * Make cron script quiet if cache is locked. Thanks to Ted Percival
+    <ted@midg3t.net> for the patch. Closes: #459344
 
  -- Otavio Salvador <otavio@debian.org>  Fri, 02 May 2008 12:07:08 -0300