Handle a # at the end of a replacement string (such as status-left)

correctly. Found by Thomas Adam.
pull/1/head
Nicholas Marriott 2011-01-03 21:30:49 +00:00
parent 3e8124009f
commit 5158dd9a8d
1 changed files with 1 additions and 1 deletions

View File

@ -456,7 +456,7 @@ status_replace(struct client *c,
break;
ch = *iptr++;
if (ch != '#') {
if (ch != '#' || *iptr == '\0') {
*optr++ = ch;
continue;
}