diff options
Diffstat (limited to 'mumctl')
| -rw-r--r-- | mumctl/src/main.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/mumctl/src/main.rs b/mumctl/src/main.rs index 124cc8c..d6c046d 100644 --- a/mumctl/src/main.rs +++ b/mumctl/src/main.rs @@ -91,13 +91,13 @@ fn main() { }; } -fn send_command(command: Command) -> Result<Option<CommandResponse>, ()> { - let (tx_client, rx_client): (IpcSender<Result<Option<CommandResponse>, ()>>, - IpcReceiver<Result<Option<CommandResponse>, ()>>) = ipc::channel().unwrap(); +fn send_command(command: Command) -> mumlib::error::Result<Option<CommandResponse>> { + let (tx_client, rx_client) = ipc::channel::<mumlib::error::Result<Option<CommandResponse>>>().unwrap(); let server_name = fs::read_to_string("/var/tmp/mumd-oneshot").unwrap(); //TODO don't panic let tx0 = IpcSender::connect(server_name).unwrap(); + tx0.send((command, tx_client)).unwrap(); rx_client.recv().unwrap() |
