From e2864327195d067728dd904f8ff72959c8097508 Mon Sep 17 00:00:00 2001 From: Martin Mares Date: Sat, 4 Dec 2010 18:47:46 +0100 Subject: [PATCH] Be ISO C89 compliant (still needed for MSVC) --- setpci.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/setpci.c b/setpci.c index 97740e8..5711e51 100644 --- a/setpci.c +++ b/setpci.c @@ -482,11 +482,12 @@ static const struct reg_name *parse_reg_name(char *name) static int parse_x32(char *c, char **stopp, unsigned int *resp) { char *stop; + unsigned long int l; if (!*c) return -1; errno = 0; - unsigned long int l = strtoul(c, &stop, 16); + l = strtoul(c, &stop, 16); if (errno) return -1; if ((l & ~0U) != l) -- 2.39.2