diff options
-rw-r--r-- | usr/src/uts/common/io/ldterm.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/usr/src/uts/common/io/ldterm.c b/usr/src/uts/common/io/ldterm.c index 1af97c86ea..ff36dab948 100644 --- a/usr/src/uts/common/io/ldterm.c +++ b/usr/src/uts/common/io/ldterm.c @@ -4069,8 +4069,10 @@ ldterm_dosig(queue_t *q, int sig, uchar_t c, int mtype, int mode) if (c != '\0') { if ((tp->t_echomp = allocb(4, BPRI_HI)) != NULL) { - (void) ldterm_echo(c, WR(q), 4, tp); - putnext(WR(q), tp->t_echomp); + if (ldterm_echo(c, WR(q), 4, tp) > 0) + putnext(WR(q), tp->t_echomp); + else + freemsg(tp->t_echomp); tp->t_echomp = NULL; } } |