From 4bd8b5c8508c2b165edd998282c82e2b29a99418 Mon Sep 17 00:00:00 2001 From: Colin Walters Date: Fri, 4 Apr 2014 16:51:37 -0400 Subject: [PATCH] switch: Always allow chronological downgrades Ideally we'd have something a bit more strict, but...without downloading the parentage, this is all we can do at the moment. --- src/ostree/ot-admin-builtin-switch.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/ostree/ot-admin-builtin-switch.c b/src/ostree/ot-admin-builtin-switch.c index ad652634..292532fe 100644 --- a/src/ostree/ot-admin-builtin-switch.c +++ b/src/ostree/ot-admin-builtin-switch.c @@ -120,7 +120,12 @@ ot_admin_builtin_switch (int argc, char **argv, OstreeSysroot *sysroot, GCancell in_status_line = FALSE; } - if (!ostree_sysroot_upgrader_pull (upgrader, 0, 0, progress, &changed, + /* Always allow older...there's not going to be a chronological + * relationship necessarily. + */ + if (!ostree_sysroot_upgrader_pull (upgrader, 0, + OSTREE_SYSROOT_UPGRADER_PULL_FLAGS_ALLOW_OLDER, + progress, &changed, cancellable, error)) goto out;