From f3f1509ba9f413aef8152ec53f91ad4d4437c0b7 Mon Sep 17 00:00:00 2001 From: reimar Date: Thu, 15 Jun 2006 08:09:03 +0000 Subject: Do not parse numbers as octal, strip leading zeroes instead. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@18721 b3059339-0415-0410-9bf9-f77b7e298cf2 --- m_option.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'm_option.c') diff --git a/m_option.c b/m_option.c index bdf0a4da11..5baeef41f6 100644 --- a/m_option.c +++ b/m_option.c @@ -143,6 +143,8 @@ static int parse_int(m_option_t* opt,char *name, char *param, void* dst, int src if (param == NULL) return M_OPT_MISSING_PARAM; + tmp_int = strtol(param, &endptr, 10); + if (*endptr) tmp_int = strtol(param, &endptr, 0); if (*endptr) { mp_msg(MSGT_CFGPARSER, MSGL_ERR, "The %s option must be an integer: %s\n",name, param); -- cgit v1.2.3