]> git.zerfleddert.de Git - proxmark3-svn/commitdiff
Fix Gcc 8 warnings (#632)
authorFl0-0 <Fl0-0@users.noreply.github.com>
Thu, 26 Jul 2018 15:17:11 +0000 (17:17 +0200)
committerpwpiwi <pwpiwi@users.noreply.github.com>
Thu, 26 Jul 2018 15:17:11 +0000 (17:17 +0200)
client/util.c

index 4f84e3b5eed7b391ae31930fe35cd25f4893dbcd..2be1e46b6fa4a03bc3c1bb170e1e7e579f349bc7 100644 (file)
@@ -226,7 +226,7 @@ char *sprint_hex_ascii(const uint8_t *data, const size_t len) {
        memset(buf, 0x00, 1024);
        size_t max_len = (len > 255) ? 255 : len;
        // max 255 bytes * 3 + 2 characters = 767 in buffer
        memset(buf, 0x00, 1024);
        size_t max_len = (len > 255) ? 255 : len;
        // max 255 bytes * 3 + 2 characters = 767 in buffer
-       sprintf(tmp, "%s| ", sprint_hex(data, max_len) );
+       sprintf(tmp, "%.765s| ", sprint_hex(data, max_len) );
        
        size_t i = 0;
        size_t pos = (max_len * 3)+2;
        
        size_t i = 0;
        size_t pos = (max_len * 3)+2;
Impressum, Datenschutz