Fix #301 -- infinite retry loop when file not found * When an integer config value is unset, return the default, if set or else fail. * If decrementing the retry counter results in a negative number (not just zero) then fail.
modified libpkg/fetch.c
@@ -92,7 +92,7 @@ pkg_fetch_file(const char *url, const char *dest, time_t t)
|
|
|
|
|
|
| - | |
| + | |
|
|
|
|
|
modified libpkg/pkg_config.c
@@ -281,8 +281,6 @@ pkg_config_int64(pkg_config_key key, int64_t *val)
|
|
|
|
|
|
| - | |
| - | |
|
|
|
|
|
@@ -299,7 +297,16 @@ pkg_config_int64(pkg_config_key key, int64_t *val)
|
|
|
|
|
|
| - | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
|
|
|
|
|