diff options
| author | Felix (xq) Queißner <git@mq32.de> | 2020-06-12 11:48:28 +0200 |
|---|---|---|
| committer | Felix (xq) Queißner <git@mq32.de> | 2020-06-12 11:48:28 +0200 |
| commit | 89263ec94135dfa03fe1e4501c780d982ee78385 (patch) | |
| tree | e923af15179e8391b5e95706fbb67de38ad46094 /src/gopherclient.cpp | |
| parent | c71a08e2b44521590a3f48e6cd6b15394890b48f (diff) | |
| download | kristall-89263ec94135dfa03fe1e4501c780d982ee78385.tar.gz | |
Fixes #7: Wrong end-of-document detection.
Diffstat (limited to 'src/gopherclient.cpp')
| -rw-r--r-- | src/gopherclient.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/gopherclient.cpp b/src/gopherclient.cpp index 2c2cdf5..74359c6 100644 --- a/src/gopherclient.cpp +++ b/src/gopherclient.cpp @@ -69,8 +69,8 @@ void GopherClient::on_readRead() if(not is_processing_binary) { // Strip the "lone dot" from gopher data - if(int index = body.indexOf(".\r\n"); index >= 0) { - body.resize(index); + if(int index = body.indexOf("\r\n.\r\n"); index >= 0) { + body.resize(index + 2); socket.close(); } } |
