Browse Source

Flush before waiting for new input, not after

tags/1.2
Timo Röhling 10 years ago
parent
commit
a4a53c7b9f
1 changed files with 1 additions and 1 deletions
  1. 1
    1
      postsrsd.c

+ 1
- 1
postsrsd.c View File

476
             key = url_decode(keybuf, sizeof(keybuf), token);
476
             key = url_decode(keybuf, sizeof(keybuf), token);
477
             if (!key) break;
477
             if (!key) break;
478
             handler[i](srs, fp, key, domain, excludes);
478
             handler[i](srs, fp, key, domain, excludes);
479
-            if (poll(&fds[2], 1, timeout * 1000) <= 0) break;
480
             fflush (fp);
479
             fflush (fp);
480
+            if (poll(&fds[2], 1, timeout * 1000) <= 0) break;
481
             line = fgets(linebuf, sizeof(linebuf), fp);
481
             line = fgets(linebuf, sizeof(linebuf), fp);
482
           }
482
           }
483
           fclose (fp);
483
           fclose (fp);

Loading…
Cancel
Save