From 85c0cb6cc2e0e14d12627dbb596bc25c5a1fc23c Mon Sep 17 00:00:00 2001 From: Ben Date: Mon, 13 Jun 2022 22:05:19 +0200 Subject: Update argtable3 and fix warnings --- src/base64.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/base64.c') diff --git a/src/base64.c b/src/base64.c index d07ea60..eea847a 100644 --- a/src/base64.c +++ b/src/base64.c @@ -177,7 +177,8 @@ unsigned char * b64t_encode(const unsigned char *src, size_t len, new_index ++; } } - out[new_index] = 0; + if(new_index) + out[new_index] = 0; *out_len = new_index; for (size_t i=0; i < *out_len; i++) { -- cgit v1.2.3