diff --git a/src/hbuf.c b/src/hbuf.c index 6c16580b1..e15bd85d5 100644 --- a/src/hbuf.c +++ b/src/hbuf.c @@ -55,6 +55,10 @@ void hbuf_str_append(struct hbuf *h, const char *line) } else if (*p == 't') *to++ = '\t'; + else { + /* unexpected escape sequence, treat as literal */ + *to++ = *p; + } p++; h->data++; }