1 2

[PATCH] Replace non-standard escape sequence with char equivalent.

Details
Message ID
<20190113040324.20512-1-dev@sgregoratto.me>
DKIM signature
pass
Download raw message
Patch: +1 -1
Fixes error messages generated from compiling with -Wall -Werror
-Wpedantic.

---
 highlight.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/highlight.c b/highlight.c
index 542d79c..a146381 100644
--- a/highlight.c
+++ b/highlight.c
@@ -51,7 +51,7 @@ static void highlight(struct highlight_state *state, struct mrsh_position *pos,
 		++state->fmt_stack_len;
 	}
 
-	fprintf(stdout, "\e[%dm", fmt);
+	fprintf(stdout, "%c[%dm", 0x1B, fmt);
 }
 
 static void highlight_str(struct highlight_state *state,
-- 
-- 
2.20.1
Details
Message ID
<O_mHhVYOGoXhjluhN5t1T2WOf38HvsNvEgt2s4D05enEIDpNEKmLWIQeYIttb8gWXoIwQJbKKvuARGklKi5KmaINqUQbUXtzw-6AHZLZILQ=@emersion.fr>
In-Reply-To
<20190113040324.20512-1-dev@sgregoratto.me> (view parent)
DKIM signature
pass
Download raw message
Pushed:

To git.sr.ht:~emersion/mrsh
   1c6cbcf..4215cfb  master -> master

Thanks!