Mercurial > sdl-ios-xcode
changeset 3206:f735edf338d3
Linux /proc/apm: handle hex and decimal (and octal!) values.
author | Ryan C. Gordon <icculus@icculus.org> |
---|---|
date | Tue, 30 Jun 2009 06:26:02 +0000 |
parents | f9a4aa1e1b34 |
children | 65fdb0961d7c |
files | src/power/linux/SDL_syspower.c |
diffstat | 1 files changed, 1 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/src/power/linux/SDL_syspower.c Tue Jun 30 05:44:00 2009 +0000 +++ b/src/power/linux/SDL_syspower.c Tue Jun 30 06:26:02 2009 +0000 @@ -318,7 +318,7 @@ int_string(char *str, int *val) { char *endptr = NULL; - *val = (int) strtol(str + 2, &endptr, 16); + *val = (int) strtol(str, &endptr, 0); return ((*str != '\0') && (*endptr == '\0')); }