diff options
| author | Kunal Mohan <kunalmohan99@gmail.com> | 2021-02-12 12:59:48 +0530 |
|---|---|---|
| committer | Kunal Mohan <kunalmohan99@gmail.com> | 2021-05-04 20:47:49 +0530 |
| commit | 6fc1a5bf921fa14209ce579348e4f1208ace81d7 (patch) | |
| tree | b0e7aed8a1bb8502e63446cceaa5aa4766dc7ef5 /src/common/mod.rs | |
| parent | remove debug log file (diff) | |
| download | sl0ppij-6fc1a5bf921fa14209ce579348e4f1208ace81d7.tar.gz sl0ppij-6fc1a5bf921fa14209ce579348e4f1208ace81d7.tar.xz sl0ppij-6fc1a5bf921fa14209ce579348e4f1208ace81d7.zip | |
another try
Diffstat (limited to 'src/common/mod.rs')
| -rw-r--r-- | src/common/mod.rs | 14 |
1 files changed, 5 insertions, 9 deletions
diff --git a/src/common/mod.rs b/src/common/mod.rs index 4c8ab4c0..c737a788 100644 --- a/src/common/mod.rs +++ b/src/common/mod.rs @@ -141,11 +141,8 @@ impl IpcSenderWithContext { } pub fn send(&mut self, msg: ApiCommand) -> std::io::Result<()> { - eprintln!("Ipcsender sending {:?}", msg); let command = bincode::serialize(&(self.err_ctx, msg)).unwrap(); - UnixStream::connect(MOSAIC_IPC_PIPE) - .unwrap() - .write_all(&command) + self.sender.write_all(&command) } } @@ -573,11 +570,10 @@ pub fn start(mut os_input: Box<dyn OsApi>, opts: CliArgs, config: Config) { os_input.unset_raw_mode(0); let goto_start_of_last_line = format!("\u{1b}[{};{}H", full_screen_ws.rows, 1); let error = format!("{}\n{}", goto_start_of_last_line, backtrace); - //let _ = os_input - // .get_stdout_writer() - // .write(error.as_bytes()) - // .unwrap(); - eprintln!("{}", error); + let _ = os_input + .get_stdout_writer() + .write(error.as_bytes()) + .unwrap(); std::process::exit(1); } AppInstruction::ToScreen(instruction) => { |
