summaryrefslogtreecommitdiffstats
path: root/runtime/tools
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2016-03-20 21:08:34 +0100
committerBram Moolenaar <Bram@vim.org>2016-03-20 21:08:34 +0100
commite18c0b39815c5a746887a509c2cd9f11fadaba07 (patch)
treeb94b501fcc8394a958fb44844892333b8d2b774d /runtime/tools
parentbe6aa46c4d8948e164f7d181dc19ed2fc4818395 (diff)
Updated runtime files.
Diffstat (limited to 'runtime/tools')
-rw-r--r--runtime/tools/demoserver.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/runtime/tools/demoserver.py b/runtime/tools/demoserver.py
index c701434b28..00fe8bfbca 100644
--- a/runtime/tools/demoserver.py
+++ b/runtime/tools/demoserver.py
@@ -50,7 +50,7 @@ class ThreadedTCPRequestHandler(socketserver.BaseRequestHandler):
if data == '':
print("=== socket closed ===")
break
- print("received: {}".format(data))
+ print("received: {0}".format(data))
try:
decoded = json.loads(data)
except ValueError:
@@ -65,7 +65,7 @@ class ThreadedTCPRequestHandler(socketserver.BaseRequestHandler):
else:
response = "what?"
encoded = json.dumps([decoded[0], response])
- print("sending {}".format(encoded))
+ print("sending {0}".format(encoded))
self.request.sendall(encoded.encode('utf-8'))
thesocket = None
@@ -87,7 +87,7 @@ if __name__ == "__main__":
server_thread.start()
print("Server loop running in thread: ", server_thread.name)
- print("Listening on port {}".format(PORT))
+ print("Listening on port {0}".format(PORT))
while True:
typed = sys.stdin.readline()
if "quit" in typed:
@@ -96,7 +96,7 @@ if __name__ == "__main__":
if thesocket is None:
print("No socket yet")
else:
- print("sending {}".format(typed))
+ print("sending {0}".format(typed))
thesocket.sendall(typed.encode('utf-8'))
server.shutdown()