From 2adb1181821a534afa76ee7e25f5f44bb6e958c1 Mon Sep 17 00:00:00 2001 From: Tom Smeding Date: Sat, 8 Aug 2020 22:03:23 +0200 Subject: protocol: Fix definitions of 'string' and 'word' --- protocol.md | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/protocol.md b/protocol.md index ff6651b..71fee05 100644 --- a/protocol.md +++ b/protocol.md @@ -10,11 +10,12 @@ both client->server and server->client, always ends with a newline (ASCII 10) character. Preliminary definitions: -- A _string_ is a series of non-zero bytes. To allow for clients written in - languages that automatically parse strings as UTF-8, argument strings should - always be valid UTF-8. However, the server currently does not care. -- A _word_ is a string without spaces (ASCII 32) or newlines. Note that the - empty string is also a valid word. +- A _string_ is a series of non-zero bytes that are not newlines (ASCII 10). To + allow for clients written in programming languages that automatically parse + strings as UTF-8, argument strings should always be valid UTF-8. However, the + server currently does not care. +- A _word_ is a string without spaces (ASCII 32) (and also without newlines). + Note that the empty string is also a valid word. There are three kinds of messages: commands from the client, command responses from the server, and push messages from the server (not to be confused with push -- cgit v1.2.3-54-g00ecf