diff options
author | Paul Mackerras <paulus@ozlabs.org> | 2023-03-18 17:34:07 +1100 |
---|---|---|
committer | Paul Mackerras <paulus@ozlabs.org> | 2023-03-18 17:34:07 +1100 |
commit | acc6cd4aab0a98d090a5f239cee56c206a9be496 (patch) | |
tree | d83bd0215ba50282b91c3caf11d92341bdf49dbe /chat/chat.c | |
parent | 3b0fe68ef1e28bd0db095a1a7c9bdcbe83a58588 (diff) | |
download | ppp-acc6cd4aab0a98d090a5f239cee56c206a9be496.tar.gz |
chat: Fix loop condition to avoid possible 1-byte buffer overrun
Signed-off-by: Paul Mackerras <paulus@ozlabs.org>
Diffstat (limited to 'chat/chat.c')
-rw-r--r-- | chat/chat.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/chat/chat.c b/chat/chat.c index fa67fd2..336c0f4 100644 --- a/chat/chat.c +++ b/chat/chat.c @@ -609,7 +609,7 @@ void terminate(int status) int c, rep_len; rep_len = strlen(report_buffer); - while (rep_len + 1 <= sizeof(report_buffer)) { + while (rep_len + 1 < sizeof(report_buffer)) { alarm(1); c = get_char(); alarm(0); |