From: Lennart Poettering Date: Mon, 6 Mar 2023 11:04:44 +0000 (+0100) Subject: dissect: shorten code a bit X-Git-Tag: v254-rc1~1072^2~3 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=6f5ef9e4c7b240d67cdefb1232c9e85e43d31586;p=thirdparty%2Fsystemd.git dissect: shorten code a bit --- diff --git a/src/dissect/dissect.c b/src/dissect/dissect.c index a688e6f32ca..8b1f1bf20c8 100644 --- a/src/dissect/dissect.c +++ b/src/dissect/dissect.c @@ -1718,29 +1718,23 @@ static int run(int argc, char *argv[]) { switch (arg_action) { case ACTION_DISSECT: - r = action_dissect(m, d); - break; + return action_dissect(m, d); case ACTION_MOUNT: - r = action_mount(m, d); - break; + return action_mount(m, d); case ACTION_LIST: case ACTION_MTREE: case ACTION_COPY_FROM: case ACTION_COPY_TO: - r = action_list_or_mtree_or_copy(m, d); - break; + return action_list_or_mtree_or_copy(m, d); case ACTION_WITH: - r = action_with(m, d); - break; + return action_with(m, d); default: assert_not_reached(); } - - return r; } DEFINE_MAIN_FUNCTION(run);