diff options
-rw-r--r-- | roff.c | 5 |
1 files changed, 3 insertions, 2 deletions
@@ -1,4 +1,4 @@ -/* $Id: roff.c,v 1.334 2018/08/18 21:37:01 schwarze Exp $ */ +/* $Id: roff.c,v 1.335 2018/08/18 22:05:43 schwarze Exp $ */ /* * Copyright (c) 2008-2012, 2014 Kristaps Dzonsons <kristaps@bsd.lv> * Copyright (c) 2010-2015, 2017, 2018 Ingo Schwarze <schwarze@openbsd.org> @@ -1214,7 +1214,8 @@ roff_res(struct roff *r, struct buf *buf, int ln, int pos) /* Discard normal comments. */ - while (stesc > start && stesc[-1] == ' ') + while (stesc > start && stesc[-1] == ' ' && + (stesc == start + 1 || stesc[-2] != '\\')) stesc--; *stesc = '\0'; break; |