We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 4eb2f25 + d62a24b commit feafdedCopy full SHA for feafded
1 file changed
src/client.rs
@@ -153,7 +153,11 @@ impl Client {
153
154
while let Ok(cmd) = conn_rx.recv() {
155
match cmd {
156
- Command::Func(func) => func(&mut conn),
+ Command::Func(func) => {
157
+ let _ = std::panic::catch_unwind(std::panic::AssertUnwindSafe(|| {
158
+ func(&mut conn);
159
+ }));
160
+ }
161
Command::Shutdown(func) => match conn.close() {
162
Ok(()) => {
163
func(Ok(()));
0 commit comments