fix binary string printing. Making sure no left over data is in static array

This commit is contained in:
iceman1001 committed 2022-08-06 13:31:46 +02:00
1 parent 62980b5038
commit 003623e5a7
3 files changed
+4 -2

No files matched your search

+2
View File
@@ -404,6 +404,8 @@ char *sprint_bytebits_bin_break(const uint8_t *data, const size_t len, const uin
// 3072 + end of line characters if broken at 8 bits
static char buf[MAX_BIN_BREAK_LENGTH] = {0};
memset(buf, 0, sizeof(buf));
char *tmp = buf;
// loop through the out_index to make sure we don't go too far