From: Michael Göhler Date: Mon, 15 Sep 2014 19:04:35 +0000 (+0200) Subject: do not print unmatched backslashes at eol X-Git-Url: https://git.danieliu.xyz/?a=commitdiff_plain;h=b0159e9e6cdf21c13cb94387146301aa000726c7;p=smdp.git do not print unmatched backslashes at eol --- diff --git a/viewer.c b/viewer.c index cede301..c4e6b90 100644 --- a/viewer.c +++ b/viewer.c @@ -440,9 +440,6 @@ void add_line(WINDOW *window, int y, int x, line_t *line, int max_cols) { // pop stack until empty to prevent formated trailing spaces while(!(stack->empty)(stack)) { switch((stack->pop)(stack)) { - case '\\': - wprintw(window, "%c", '\\'); - break; // disable highlight case '*': wattron(window, COLOR_PAIR(CP_WHITE)); @@ -451,6 +448,7 @@ void add_line(WINDOW *window, int y, int x, line_t *line, int max_cols) { case '_': wattroff(window, A_UNDERLINE); break; + // do nothing for backslashes } } }