diff options
author | Christian Pointner <equinox@anytun.org> | 2018-06-08 18:48:22 +0200 |
---|---|---|
committer | Christian Pointner <equinox@anytun.org> | 2018-06-08 19:45:44 +0200 |
commit | fefe6f78a67f2caf2125981724b154157a0247b4 (patch) | |
tree | 61c7bdc9df828649631ea6a9b91f80b5ecd28370 | |
parent | updated version and rebuilt manpage (diff) |
fix another off-by-one error in sprintf
-rw-r--r-- | src/log.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -265,7 +265,7 @@ void log_print_hex_dump(log_prio_t prio, const u_int8_t* buf, u_int32_t len) for(i=0; i < len; i++) { if(((i+1)*3) >= (MSG_LENGTH_MAX - offset)) break; - snprintf(ptr, 3, "%02X ", buf[i]); + snprintf(ptr, 4, "%02X ", buf[i]); ptr+=3; } } |