summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 711efc4)
raw | patch | inline | side by side (parent: 711efc4)
author | oetiker <oetiker@a5681a0c-68f1-0310-ab6d-d61299d08faa> | |
Tue, 11 Aug 2009 14:00:57 +0000 (14:00 +0000) | ||
committer | oetiker <oetiker@a5681a0c-68f1-0310-ab6d-d61299d08faa> | |
Tue, 11 Aug 2009 14:00:57 +0000 (14:00 +0000) |
program/src/rrd_restore.c | patch | blob | history |
index 6acfa4e07395be0f9bc5fefc11e6437dfb38745f..c5cbcd2dffae485242236e9bd7793dd45054a604 100644 (file)
end_ptr = NULL;
temp = strtol(str_ptr, &end_ptr, 0);
- xmlFree(str_ptr);
if (str_ptr == end_ptr) {
rrd_set_error("get_long_from_node: Cannot parse buffer as long: %s",
str_ptr);
+ xmlFree(str_ptr);
return (-1);
}
-
+ xmlFree(str_ptr);
*value = temp;
return (0);
end_ptr = NULL;
temp = strtoul(str_ptr, &end_ptr, 0);
- xmlFree(str_ptr);
if (str_ptr == end_ptr) {
rrd_set_error("get_ulong_from_node: Cannot parse buffer as unsigned long: %s",
str_ptr);
+ xmlFree(str_ptr);
return (-1);
}
-
+
+ xmlFree(str_ptr);
*value = temp;
return (0);
end_ptr = NULL;
temp = strtoll(str_ptr, &end_ptr, 10);
- xmlFree(str_ptr);
if (str_ptr == end_ptr) {
rrd_set_error("get_llong_from_node: Cannot parse buffer as unsigned long long: %s",
str_ptr);
+ xmlFree(str_ptr);
return (-1);
}
-
+ xmlFree(str_ptr);
*value = temp;
return (0);
end_ptr = NULL;
temp = strtod(str_ptr, &end_ptr);
- xmlFree(str_ptr);
if (str_ptr == end_ptr) {
rrd_set_error
("get_double_from_node: Cannot parse buffer as double: %s",
str_ptr);
+ xmlFree(str_ptr);
return (-1);
}
-
+ xmlFree(str_ptr);
*value = temp;
return (0);