diff mbox

[ANNOUNCE] cpupowerutils - cpufrequtils extended with quite some features

Message ID 20110312044010.GB3634@zhy (mailing list archive)
State New, archived
Headers show

Commit Message

Yong Zhang March 12, 2011, 4:40 a.m. UTC
None
diff mbox

Patch

--- utils/helpers/sysfs-orig.c	2011-03-12 12:32:06.179827929 +0800
+++ utils/helpers/sysfs.c	2011-03-12 12:35:21.512796546 +0800
@@ -111,7 +111,7 @@ 
 						     unsigned int idlestate,
 						     enum idlestate_value which)
 {
-	unsigned long value;
+	unsigned long long value;
 	unsigned int len;
 	char linebuf[MAX_LINE_LEN];
 	char *endp;
@@ -126,7 +126,7 @@ 
 		return 0;
 	}
 
-	value = strtoul(linebuf, &endp, 0);
+	value = strtoull(linebuf, &endp, 0);
 
 	if ( endp == linebuf || errno == ERANGE )
 		return 0;