]> git.droids-corp.org - dpdk.git/blobdiff - examples/exception_path/main.c
eal: fix usage of printf-like functions
[dpdk.git] / examples / exception_path / main.c
index 78ed91d7c78e16a0cd42d2d6036c8a5aace3cdaa..3ece2ac295ad709132fa1ac3502cb9e437692600 100644 (file)
@@ -229,7 +229,7 @@ static int tap_create(char *name)
        ifr.ifr_flags = IFF_TAP | IFF_NO_PI;
 
        if (name && *name)
-               rte_snprintf(ifr.ifr_name, IFNAMSIZ, name);
+               rte_snprintf(ifr.ifr_name, IFNAMSIZ, "%s", name);
 
        ret = ioctl(fd, TUNSETIFF, (void *) &ifr);
        if (ret < 0) {
@@ -238,7 +238,7 @@ static int tap_create(char *name)
        }
 
        if (name)
-               rte_snprintf(name, IFNAMSIZ, ifr.ifr_name);
+               rte_snprintf(name, IFNAMSIZ, "%s", ifr.ifr_name);
 
        return fd;
 }