mirror of
https://github.com/moparisthebest/pacman
synced 2024-12-22 15:58:50 -05:00
check config_new return value
Signed-off-by: Andrew Gregory <andrew.gregory.8@gmail.com> Signed-off-by: Allan McRae <allan@archlinux.org>
This commit is contained in:
parent
fb8437b588
commit
b0dc547fcb
@ -1045,7 +1045,10 @@ int main(int argc, char *argv[])
|
||||
setuseragent();
|
||||
|
||||
/* init config data */
|
||||
config = config_new();
|
||||
if(!(config = config_new())) {
|
||||
/* config_new prints the appropriate error message */
|
||||
cleanup(1);
|
||||
}
|
||||
|
||||
/* disable progressbar if the output is redirected */
|
||||
if(!isatty(fileno(stdout))) {
|
||||
|
Loading…
Reference in New Issue
Block a user