From 0f97d1da43d5e3d41104d7f784ef3f8ffa47692c Mon Sep 17 00:00:00 2001 From: Lukas Krickl Date: Sun, 18 Feb 2024 04:58:23 +0100 Subject: [PATCH] Removed a magick number --- src/ulas.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/ulas.c b/src/ulas.c index c26cd8d..a49b0d9 100644 --- a/src/ulas.c +++ b/src/ulas.c @@ -2143,10 +2143,11 @@ const struct ulas_instr ULASINSTRS[] = { {NULL}}; +#define ULAS_INSTRBUF_MIN 4 int ulas_asminstr(char *dst, unsigned long max, const char **line, unsigned long n) { const char *start = *line; - if (max < 4) { + if (max < ULAS_INSTRBUF_MIN) { ULASPANIC("Instruction buffer is too small!"); return -1; } -- 2.30.2