diff options
author | Aaron Griffin <aaronmgriffin@gmail.com> | 2007-12-14 18:35:46 +0100 |
---|---|---|
committer | Dan McGee <dan@archlinux.org> | 2007-12-18 03:56:35 +0100 |
commit | a4b81387974e6b36c6fbc541b543d6d67882eadd (patch) | |
tree | 1a2bfb19f8fe893999beb2a40218a91efa901870 | |
parent | e5cdac7d48cb0bb4c3df6a4e0d1e84c195ff2b54 (diff) | |
download | pacman-a4b81387974e6b36c6fbc541b543d6d67882eadd.tar.gz pacman-a4b81387974e6b36c6fbc541b543d6d67882eadd.tar.xz |
Allow unreadable Include files to be non-fatal
Signed-off-by: Aaron Griffin <aaronmgriffin@gmail.com>
[Dan: remove unused variable, make parseconfig static]
Signed-off-by: Dan McGee <dan@archlinux.org>
-rw-r--r-- | src/pacman/pacman.c | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/src/pacman/pacman.c b/src/pacman/pacman.c index 1f26c74f..70ef7767 100644 --- a/src/pacman/pacman.c +++ b/src/pacman/pacman.c @@ -643,12 +643,9 @@ static int _parseconfig(const char *file, const char *givensection, } else { /* directives with settings */ if(strcmp(key, "Include") == 0 || strcmp(upperkey, "INCLUDE") == 0) { - int ret; pm_printf(PM_LOG_DEBUG, "config: including %s\n", ptr); - ret = _parseconfig(ptr, section, db); - if(ret != 0) { - return(ret); - } + _parseconfig(ptr, section, db); + /* Ignore include failures... assume non-critical */ } else if(strcmp(section, "options") == 0) { if(strcmp(key, "NoUpgrade") == 0 || strcmp(upperkey, "NOUPGRADE") == 0) { @@ -736,7 +733,7 @@ static int _parseconfig(const char *file, const char *givensection, * @param file path to the config file. * @return 0 on success, non-zero on error */ -int parseconfig(const char *file) +static int parseconfig(const char *file) { /* call the real parseconfig function with a null section & db argument */ return(_parseconfig(file, NULL, NULL)); |