diff --git a/drivers/net/mrvl/mrvl_qos.c b/drivers/net/mrvl/mrvl_qos.c index 54e682a36f..7c9943aac6 100644 --- a/drivers/net/mrvl/mrvl_qos.c +++ b/drivers/net/mrvl/mrvl_qos.c @@ -99,6 +99,7 @@ get_val_securely(const char *string, uint32_t *val) if (len == 0) return -1; + errno = 0; *val = strtoul(string, &endptr, 0); if (errno != 0 || RTE_PTR_DIFF(endptr, string) != len) return -2;