summaryrefslogtreecommitdiff
path: root/src/state.c
diff options
context:
space:
mode:
authorNatanael Copa <ncopa@alpinelinux.org>2009-05-24 15:20:35 +0200
committerNatanael Copa <ncopa@alpinelinux.org>2009-05-24 15:20:35 +0200
commitd584b19c32a5febdd43aabe5ab703622192903eb (patch)
tree85dd6bbf0255559328c38d53d7bdef99ecca1896 /src/state.c
parent651aa71ac2dfc6d3c78e106cacb8fa699095f845 (diff)
downloadapk-tools-d584b19c32a5febdd43aabe5ab703622192903eb.tar.gz
apk-tools-d584b19c32a5febdd43aabe5ab703622192903eb.tar.bz2
apk-tools-d584b19c32a5febdd43aabe5ab703622192903eb.tar.xz
apk-tools-d584b19c32a5febdd43aabe5ab703622192903eb.zip
state: upgrade deps for given packages to add -u
Diffstat (limited to 'src/state.c')
-rw-r--r--src/state.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/state.c b/src/state.c
index c1149ea..9d6e9a8 100644
--- a/src/state.c
+++ b/src/state.c
@@ -412,10 +412,6 @@ int apk_state_lock_name(struct apk_state *state,
}
}
- /* If the chosen package is installed, all is done here */
- if (oldpkg == newpkg)
- return 0;
-
/* First we need to make sure the dependants of the old package
* still have their dependencies ok. */
if (oldpkg != NULL) {
@@ -434,6 +430,10 @@ int apk_state_lock_name(struct apk_state *state,
return r;
}
+ /* If the chosen package is installed, all is done here */
+ if (oldpkg == newpkg)
+ return 0;
+
/* Track change */
r = apk_state_add_change(state, oldpkg, newpkg);
if (r != 0)