mirror of
https://github.com/denoland/deno.git
synced 2024-11-25 15:29:32 -05:00
fix(runtime): return error instead of panicking for windows signals (#11940)
This commit is contained in:
parent
2c2e3ec1ca
commit
d85ccce65b
1 changed files with 5 additions and 3 deletions
|
@ -1,4 +1,6 @@
|
||||||
// Copyright 2018-2021 the Deno authors. All rights reserved. MIT license.
|
// Copyright 2018-2021 the Deno authors. All rights reserved. MIT license.
|
||||||
|
#[cfg(not(unix))]
|
||||||
|
use deno_core::error::generic_error;
|
||||||
use deno_core::error::type_error;
|
use deno_core::error::type_error;
|
||||||
use deno_core::error::AnyError;
|
use deno_core::error::AnyError;
|
||||||
use deno_core::op_async_unref;
|
use deno_core::op_async_unref;
|
||||||
|
@ -194,7 +196,7 @@ pub fn op_signal_bind(
|
||||||
_args: (),
|
_args: (),
|
||||||
_: (),
|
_: (),
|
||||||
) -> Result<(), AnyError> {
|
) -> Result<(), AnyError> {
|
||||||
unimplemented!();
|
Err(generic_error("not implemented"))
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(not(unix))]
|
#[cfg(not(unix))]
|
||||||
|
@ -203,7 +205,7 @@ fn op_signal_unbind(
|
||||||
_args: (),
|
_args: (),
|
||||||
_: (),
|
_: (),
|
||||||
) -> Result<(), AnyError> {
|
) -> Result<(), AnyError> {
|
||||||
unimplemented!();
|
Err(generic_error("not implemented"))
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(not(unix))]
|
#[cfg(not(unix))]
|
||||||
|
@ -212,5 +214,5 @@ async fn op_signal_poll(
|
||||||
_args: (),
|
_args: (),
|
||||||
_: (),
|
_: (),
|
||||||
) -> Result<(), AnyError> {
|
) -> Result<(), AnyError> {
|
||||||
unimplemented!();
|
Err(generic_error("not implemented"))
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue