[RFC,2/4] criu/action-scripts: remove duplicate code

Submitted by Adrian Reber on Aug. 3, 2018, 3:28 p.m.

Details

Message ID 20180803152808.25928-3-adrian@lisas.de
State Rejected
Series "Series without cover letter"
Headers show

Commit Message

Adrian Reber Aug. 3, 2018, 3:28 p.m.
From: Adrian Reber <areber@redhat.com>

Signed-off-by: Adrian Reber <areber@redhat.com>
---
 criu/action-scripts.c | 10 +---------
 1 file changed, 1 insertion(+), 9 deletions(-)

Patch hide | download patch | download mbox

diff --git a/criu/action-scripts.c b/criu/action-scripts.c
index 7b78a1360..d382547cd 100644
--- a/criu/action-scripts.c
+++ b/criu/action-scripts.c
@@ -126,15 +126,7 @@  int run_scripts(enum script_actions act)
 		return 0;
 
 	if (scripts_mode == SCRIPTS_RPC) {
-		int rpc_sk;
-
-		pr_debug("\tRPC\n");
-		rpc_sk = get_service_fd(RPC_SK_OFF);
-		if (rpc_sk < 0) {
-			ret = -1;
-			goto out;
-		}
-		ret = send_criu_rpc_script(act, (char *)action, rpc_sk, -1);
+		ret = rpc_send_fd(act, -1);
 		goto out;
 	}