diff options
author | ꦌꦫꦶꦏ꧀ꦦꦿꦧꦮꦑꦩꦭ꧀ <prabowo@darapsa.org> | 2022-10-05 17:56:51 +0800 |
---|---|---|
committer | ꦌꦫꦶꦏ꧀ꦦꦿꦧꦮꦑꦩꦭ꧀ <prabowo@darapsa.org> | 2022-10-05 17:56:51 +0800 |
commit | 1c7e8d93fbb4f131250f737b11a8ad99df167ea8 (patch) | |
tree | 3e10804377de3f591d8e283d4d54bf4a84efce53 | |
parent | b7086a2580131680a74d4b56bbf0f26085c6bab6 (diff) |
BIO_get_mem_* seems to contain \n
-rw-r--r-- | midtrans.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -41,7 +41,7 @@ void midtrans_init(_Bool production, const char *api_key, const char *cainfo) BIO_write(b64, basic, basic_len); BIO_flush(b64); char *pp; - long base64_len = BIO_get_mem_data(b64, &pp); + long base64_len = BIO_get_mem_data(b64, &pp) - 1; char base64[base64_len + 1]; strlcpy(base64, pp, base64_len + 1); BIO_free_all(b64); |