Fix generation of html with missing images
authorMichal Sojka <sojkam1@fel.cvut.cz>
Thu, 27 Aug 2009 16:44:25 +0000 (18:44 +0200)
committerMichal Sojka <sojkam1@fel.cvut.cz>
Thu, 27 Aug 2009 16:44:25 +0000 (18:44 +0200)
tests/genhtml.py

index 8fd6da2..9e3263e 100755 (executable)
@@ -88,10 +88,10 @@ td { border: 1px solid lightgray; padding: 4px;}
                     for img in dircache.listdir(dthumb):
                         print >>html, "<a href='%s/%s'><img src='%s/thumb/%s'></a>" % (d, img, d, img)
                 except OSError:
-                    print "error"
-                    print >>html, "</td>"
-                    print >>html, "</tr>"
-                    print >> html, """
+                    print "warning: no images in %s?"%dthumb
+                print >>html, "</td>"
+            print >>html, "</tr>"
+        print >> html, """
 </table>
 </body>
 """