diff options
Diffstat (limited to 'drivers/tty/tty_buffer.c')
-rw-r--r-- | drivers/tty/tty_buffer.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/tty/tty_buffer.c b/drivers/tty/tty_buffer.c index e99f1c5b1df6..41b9a7ccce08 100644 --- a/drivers/tty/tty_buffer.c +++ b/drivers/tty/tty_buffer.c @@ -458,6 +458,8 @@ int tty_ldisc_receive_buf(struct tty_ldisc *ld, unsigned char *p, if (count && ld->ops->receive_buf) ld->ops->receive_buf(ld->tty, p, f, count); } + if (count > 0) + memset(p, 0, count); return count; } EXPORT_SYMBOL_GPL(tty_ldisc_receive_buf); |