mirror of
https://github.com/jeremyd/ergo.git
synced 2026-07-19 22:18:11 -07:00
more memory-efficient implementation of line reading
This commit is contained in:
@@ -69,10 +69,6 @@ func (socket *Socket) Read() (string, error) {
|
||||
|
||||
if err == io.EOF {
|
||||
socket.Close()
|
||||
// process last message properly (such as ERROR/QUIT/etc), just fail next reads/writes
|
||||
if line != "" {
|
||||
err = nil
|
||||
}
|
||||
}
|
||||
|
||||
return line, err
|
||||
|
||||
Reference in New Issue
Block a user