(recv_input): Skip CR when creating command buffer.

This prevents mismatches between command buffer and
the response from the server during the secure check.
This commit is contained in:
Ron Koenderink 2007-12-08 23:09:56 +00:00
parent 9b87ff70be
commit da6e711e5c

View file

@ -181,7 +181,7 @@ recv_input(int fd, struct ring *inbuf)
for (i = -n; i < 0; i++) {
ch = ring_peek(inbuf, i);
assert(ch != EOF);
if (lbuf_putc(&cmdbuf, ch)) {
if (ch != '\r' && lbuf_putc(&cmdbuf, ch)) {
line = lbuf_line(&cmdbuf);
if (auxfp)
fputs(line, auxfp);