]> git.plutz.net Git - serve0/commitdiff
ignore zero size cache files
authorpaul <paul@plutz.net>
Tue, 5 Jul 2016 10:46:28 +0000 (10:46 +0000)
committerpaul <paul@plutz.net>
Tue, 5 Jul 2016 10:46:28 +0000 (10:46 +0000)
svn path=/trunk/; revision=138

pages/list.sh

index 337676e7c1d56b531ee9045876562818fc623388..a9eeb331720e45d97c1ce2e8d183287fc12c6c31 100755 (executable)
@@ -103,7 +103,7 @@ genlist(){
 selectionlist() {
   cachebase="?o=${order}&s=${search//\//}&f=${filter//\//}"
   cache="${_DATA}/cache/${cachebase}"
-  if [ "$cache" -nt ${_DATA}/videos -a "$cache" -nt ${_DATA}/meta ]; then
+  if [ -s "$cache" -a "$cache" -nt ${_DATA}/videos -a "$cache" -nt ${_DATA}/meta ]; then
     cat "$cache"
   else
     filterex="s;^([0-9]+\t){3}(.+)\n.*$;\2;p"