From 882ea431833a23f8e0f0636bb89641087c1724f4 Mon Sep 17 00:00:00 2001 From: Chaoqian Xu Date: Thu, 19 Dec 2024 10:38:19 +0800 Subject: [PATCH] refactor(shell): Use &self instead of self to allow kill to be called multiple times. --- plugins/shell/src/process/mod.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/shell/src/process/mod.rs b/plugins/shell/src/process/mod.rs index 44f037b0..ac801834 100644 --- a/plugins/shell/src/process/mod.rs +++ b/plugins/shell/src/process/mod.rs @@ -75,7 +75,7 @@ impl CommandChild { } /// Sends a kill signal to the child. - pub fn kill(self) -> crate::Result<()> { + pub fn kill(&self) -> crate::Result<()> { self.inner.kill()?; Ok(()) }