diff options
author | Emanuele Giaquinta <e.giaquinta@glauco.it> | 2008-10-07 15:58:24 -0700 |
---|---|---|
committer | Emanuele Giaquinta <e.giaquinta@glauco.it> | 2008-10-07 15:58:24 -0700 |
commit | 3da4fe1a59da55332e67db06c4b3386a0ccc3e8b (patch) | |
tree | f550cb185ff3a7afcee7f84286af715a6fd1a05c /mutt_socket.c | |
parent | ad3eb6918326118a67cc7a94b8fc2483ed1bfe20 (diff) |
Minor simplification in mutt_socket_readln_d
Diffstat (limited to 'mutt_socket.c')
-rw-r--r-- | mutt_socket.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/mutt_socket.c b/mutt_socket.c index 4d9f499d..8a8874c4 100644 --- a/mutt_socket.c +++ b/mutt_socket.c @@ -205,9 +205,8 @@ int mutt_socket_readln_d (char* buf, size_t buflen, CONNECTION* conn, int dbg) /* strip \r from \r\n termination */ if (i && buf[i-1] == '\r') - buf[--i] = '\0'; - else - buf[i] = '\0'; + i--; + buf[i] = '\0'; dprint (dbg, (debugfile, "%d< %s\n", conn->fd, buf)); |