Skip to content

Commit

Permalink
src: improvements on #4: code review & add exmaple
Browse files Browse the repository at this point in the history
- Code review pull request

- Add icon character on show_lines example to show that
even icon multibyte characters works
  • Loading branch information
OmarCastro committed May 9, 2020
1 parent 51b269b commit 42b5cbd
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions examples/show_lines.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ while printf ''; do
{"text":"json with urgent flag", "urgent":true},
{"text":"json with highlight flag", "highlight": true},
{"text":"multi-byte unicode: •"},
{"text":"icon unicode character: 😀"},
{"text":"json <i>with</i> <b>markup</b> <b><i>flag</i></b>", "markup": true},
{"text":"json <i>toggling</i> <b>markup</b> flag", "markup": $toggleMarkup},
{"text":"json <i>without</i> <b>markup</b> <b><i>flag</i></b>", "markup": false},
Expand Down
2 changes: 1 addition & 1 deletion src/blocks.c
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ typedef struct
utils
***************/

void json_escape(char *in, char *out) {
void json_escape(const char *in, char *out) {
while (*in) {
switch (*in) {
case '\\':
Expand Down

0 comments on commit 42b5cbd

Please sign in to comment.