examples: fix port mask parsing failure handling
[dpdk.git] / examples / ioat / ioatfwd.c
index b66ee73..75d8d5b 100644 (file)
@@ -584,7 +584,7 @@ ioat_parse_portmask(const char *portmask)
        /* Parse hexadecimal string */
        pm = strtoul(portmask, &end, 16);
        if ((portmask[0] == '\0') || (end == NULL) || (*end != '\0'))
-               return -1;
+               return 0;
 
        return pm;
 }