The parsed timeval is unsigned.

This commit is contained in:
Tobias Brunner
2010-03-03 17:34:49 +01:00
parent fc1afcc89e
commit 465ccdc8cf
+2 -2
View File
@@ -293,8 +293,8 @@ static u_int32_t get_time(private_settings_t *this, char *key, u_int32_t def, ..
if (value)
{
errno = 0;
timeval = strtol(value, &endptr, 10);
if (errno == 0 && timeval >= 0)
timeval = strtoul(value, &endptr, 10);
if (errno == 0)
{
switch (*endptr)
{