From a27f993600a518ef6a15bd7fb29575b218b58a0a Mon Sep 17 00:00:00 2001 From: Dan McGee Date: Mon, 19 Sep 2011 21:01:26 -0500 Subject: Split package validation and load loops This adds a some new callback event and progress codes for package loading, which was formerly bundled in with package validation before. The main sync.c loop where loading occurred is now two loops running sequentially. The behavior should not change with this patch outside of progress and event display; more changes will come in following patches. Signed-off-by: Dan McGee --- src/pacman/callback.c | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'src/pacman') diff --git a/src/pacman/callback.c b/src/pacman/callback.c index fffaf2ed..4fdd8f37 100644 --- a/src/pacman/callback.c +++ b/src/pacman/callback.c @@ -206,6 +206,11 @@ void cb_event(alpm_event_t event, void *data1, void *data2) printf(_("checking package integrity...\n")); } break; + case ALPM_EVENT_LOAD_START: + if(config->noprogressbar) { + printf(_("loading package files...\n")); + } + break; case ALPM_EVENT_DELTA_INTEGRITY_START: printf(_("checking delta integrity...\n")); break; @@ -238,6 +243,7 @@ void cb_event(alpm_event_t event, void *data1, void *data2) case ALPM_EVENT_RESOLVEDEPS_DONE: case ALPM_EVENT_INTERCONFLICTS_DONE: case ALPM_EVENT_INTEGRITY_DONE: + case ALPM_EVENT_LOAD_DONE: case ALPM_EVENT_DELTA_INTEGRITY_DONE: case ALPM_EVENT_DELTA_PATCHES_DONE: case ALPM_EVENT_DISKSPACE_DONE: @@ -408,6 +414,9 @@ void cb_progress(alpm_progress_t event, const char *pkgname, int percent, case ALPM_PROGRESS_INTEGRITY_START: opr = _("checking package integrity"); break; + case ALPM_PROGRESS_LOAD_START: + opr = _("loading package files"); + break; default: return; } -- cgit v1.2.3-70-g09d2