1
0
mirror of https://github.com/tmate-io/tmate-ssh-server.git synced 2020-11-18 19:53:51 -08:00

Don't send zero-length when we have a \0.

This commit is contained in:
Nicholas Marriott 2007-10-19 23:25:33 +00:00
parent 8f6bc501d1
commit 5c2d7b2a9a

View File

@ -1,4 +1,4 @@
/* $Id: input.c,v 1.24 2007-10-19 10:21:33 nicm Exp $ */
/* $Id: input.c,v 1.25 2007-10-19 23:25:33 nicm Exp $ */
/*
* Copyright (c) 2007 Nicholas Marriott <nicm@users.sourceforge.net>
@ -246,7 +246,7 @@ void *
input_state_title_next(u_char ch, struct input_ctx *ictx)
{
if (ch == '\007') {
ictx->title_buf[ictx->title_len] = '\0';
ictx->title_buf[ictx->title_len++] = '\0';
switch (ictx->title_type) {
case 0:
strlcpy(ictx->s->title,