summaryrefslogtreecommitdiff
path: root/src/man.c
diff options
context:
space:
mode:
authorNick Wellnhofer <wellnhofer@aevum.de>2016-03-12 11:29:55 +0100
committerNick Wellnhofer <wellnhofer@aevum.de>2016-03-12 11:51:31 +0100
commit6135e9b953747365358f7f2e23e53cc0e4a701b2 (patch)
treed93788a09c7548857d3d7a35c64c3ba51493d075 /src/man.c
parent0e216b4044f1cbbf30df4e378d51d91a0267e680 (diff)
Don't use variable length arrays
They're not supported by MSVC.
Diffstat (limited to 'src/man.c')
-rw-r--r--src/man.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/man.c b/src/man.c
index 2ce7540..3d8bc20 100644
--- a/src/man.c
+++ b/src/man.c
@@ -14,6 +14,7 @@
#define LIT(s) renderer->out(renderer, s, false, LITERAL)
#define CR() renderer->cr(renderer)
#define BLANKLINE() renderer->blankline(renderer)
+#define LIST_NUMBER_SIZE 20
// Functions to convert cmark_nodes to groff man strings.
static void S_outc(cmark_renderer *renderer, cmark_escaping escape, int32_t c,
@@ -110,7 +111,6 @@ static int S_render_node(cmark_renderer *renderer, cmark_node *node,
tmp = tmp->prev;
list_number += 1;
}
- const size_t LIST_NUMBER_SIZE = 20;
char list_number_s[LIST_NUMBER_SIZE];
snprintf(list_number_s, LIST_NUMBER_SIZE, "\"%d.\" 4", list_number);
LIT(list_number_s);