From f587edd849f8e2f31f179c67e86363feec2d4051 Mon Sep 17 00:00:00 2001 From: "Yukihiro \"Matz\" Matsumoto" Date: Tue, 23 Aug 2022 15:05:27 +0900 Subject: [PATCH] pack.c: need extra space for the terminal NULL. --- mrbgems/mruby-pack/src/pack.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/mrbgems/mruby-pack/src/pack.c b/mrbgems/mruby-pack/src/pack.c index f954f1339..3ae576dbe 100644 --- a/mrbgems/mruby-pack/src/pack.c +++ b/mrbgems/mruby-pack/src/pack.c @@ -70,9 +70,9 @@ enum pack_type { #define PACK_BASE64_IGNORE 0xff #define PACK_BASE64_PADDING 0xfe -const static unsigned char base64chars[64] = +const static unsigned char base64chars[] = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"; -const static unsigned char base64_dec_tab[128] = +const static unsigned char base64_dec_tab[] = "\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff" "\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff" "\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\x3e\xff\xff\xff\x3f"