mirror of
https://github.com/moparisthebest/pacman
synced 2025-01-10 21:38:19 -05:00
* Move sync *after* transaction init (lock file). We don't want to stomp on the
databases while another instance of pacman /could/ be reading them.
This commit is contained in:
parent
07b0092736
commit
12fdce244c
@ -372,16 +372,6 @@ int pacman_sync(list_t *targets)
|
||||
return(sync_cleancache(config->op_s_clean));
|
||||
}
|
||||
|
||||
if(config->op_s_sync) {
|
||||
/* grab a fresh package list */
|
||||
MSG(NL, _(":: Synchronizing package databases...\n"));
|
||||
alpm_logaction(_("synchronizing package lists"));
|
||||
if(!sync_synctree(config->op_s_sync, pmc_syncs)) {
|
||||
ERR(NL, _("failed to synchronize any databases"));
|
||||
return(1);
|
||||
}
|
||||
}
|
||||
|
||||
if(config->op_s_search) {
|
||||
return(sync_search(pmc_syncs, targets));
|
||||
}
|
||||
@ -409,6 +399,17 @@ int pacman_sync(list_t *targets)
|
||||
return(1);
|
||||
}
|
||||
|
||||
if(config->op_s_sync) {
|
||||
/* grab a fresh package list */
|
||||
MSG(NL, _(":: Synchronizing package databases...\n"));
|
||||
alpm_logaction(_("synchronizing package lists"));
|
||||
if(!sync_synctree(config->op_s_sync, pmc_syncs)) {
|
||||
ERR(NL, _("failed to synchronize any databases"));
|
||||
return(1);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
if(config->op_s_upgrade) {
|
||||
MSG(NL, _(":: Starting full system upgrade...\n"));
|
||||
alpm_logaction(_("starting full system upgrade"));
|
||||
|
Loading…
Reference in New Issue
Block a user