serve: make sure to print "listening at" message immediately
If stdout is piped, status message won't be flushed until client connects to
the server and access log is written to stdout. It seems bad idea to queue
start-up banner of server process.
--- a/mercurial/commands.py Fri Jun 27 15:20:50 2014 -0700
+++ b/mercurial/commands.py Sat Jun 28 13:02:44 2014 +0900
@@ -5322,6 +5322,7 @@
write = self.ui.write
write(_('listening at http://%s%s/%s (bound to %s:%d)\n') %
(fqaddr, port, prefix, bindaddr, self.httpd.port))
+ self.ui.flush() # avoid buffering of status message
def run(self):
self.httpd.serve_forever()