1
0
mirror of https://github.com/UzixLS/picocom.git synced 2025-07-19 07:21:18 +03:00

fixed logging of local echo

This commit is contained in:
Joe Merten
2016-12-08 15:25:36 +01:00
parent eca0a54492
commit 7fe5400848

View File

@ -1214,7 +1214,7 @@ loop(void)
if ( n <= 0 )
fatal("write to term failed: %s", strerror(errno));
if ( opts.lecho && opts.log_filename )
if ( writen_ni(log_fd, tty_q.buff, sz) < sz )
if ( writen_ni(log_fd, tty_q.buff, n) < n )
fatal("write to logfile failed: %s", strerror(errno));
memmove(tty_q.buff, tty_q.buff + n, tty_q.len - n);
tty_q.len -= n;