fix infinite loop in summary.awk

This commit is contained in:
Alyssa Milburn 2014-07-30 13:24:44 +02:00
parent 926de8edc1
commit 29240f7331
1 changed files with 1 additions and 1 deletions

View File

@ -25,7 +25,7 @@ BEGIN {
print " <h2>Rankings</h2>";
print " <p>Over the last " ngames" games only.</p>";
print " <ol>";
for (i = rounds - ngames - 1; i < rounds; i += 1) {
for (i = rounds - ngames - 1; i > 0 && i < rounds; i += 1) {
fn = sprintf("round-%04d.html", i)
while (getline < fn) {
if ($2 == "score") {