572a44
From 6710995e2c264939da4d383b5d37724c46282cdc Mon Sep 17 00:00:00 2001
572a44
From: Stefan Beller <stefanbeller@googlemail.com>
572a44
Date: Fri, 3 Jan 2014 20:33:20 +0100
572a44
Subject: [PATCH] swap: remove if/else with the same data path
572a44
572a44
This was introduced in e1770af812 (2012-02-03, swap: replace failure
572a44
boolean by result enum).
572a44
572a44
This just removes unneeded lines of code, no functional change.
572a44
---
572a44
 src/core/swap.c | 5 +----
572a44
 1 file changed, 1 insertion(+), 4 deletions(-)
572a44
572a44
diff --git a/src/core/swap.c b/src/core/swap.c
572a44
index f295b65..727bb95 100644
572a44
--- a/src/core/swap.c
572a44
+++ b/src/core/swap.c
572a44
@@ -959,10 +959,7 @@ static void swap_sigchld_event(Unit *u, pid_t pid, int code, int status) {
572a44
         case SWAP_DEACTIVATING_SIGKILL:
572a44
         case SWAP_DEACTIVATING_SIGTERM:
572a44
 
572a44
-                if (f == SWAP_SUCCESS)
572a44
-                        swap_enter_dead(s, f);
572a44
-                else
572a44
-                        swap_enter_dead(s, f);
572a44
+                swap_enter_dead(s, f);
572a44
                 break;
572a44
 
572a44
         default: