mirror: mirror --set/--unset fails when --path is not used

Before swupd_init if --path is not used, path_prefix is NULL. Calling
set_default_path_prefix() to force it back to correct value.

Signed-off-by: Otavio Pontes <otavio.pontes@intel.com>
This commit is contained in:
Otavio Pontes
2020-04-09 09:29:08 -07:00
parent f3bb9765da
commit e309850ea1
+3
View File
@@ -364,6 +364,9 @@ enum swupd_code mirror_main(int argc, char **argv)
print_help();
return SWUPD_INVALID_OPTION;
}
if (!globals.path_prefix) {
set_default_path_prefix();
}
progress_init_steps("mirror", steps_in_mirror);