mirror of
https://github.com/romanz/electrs.git
synced 2025-02-24 06:57:53 +01:00
Gracefully exit on SIGTERM
This commit is contained in:
parent
74dfef8f09
commit
6a4def0459
1 changed files with 1 additions and 1 deletions
|
@ -12,7 +12,7 @@ pub struct Waiter {
|
|||
impl Waiter {
|
||||
pub fn new() -> Waiter {
|
||||
Waiter {
|
||||
signal: chan_signal::notify(&[chan_signal::Signal::INT]),
|
||||
signal: chan_signal::notify(&[chan_signal::Signal::INT, chan_signal::Signal::TERM]),
|
||||
}
|
||||
}
|
||||
pub fn wait(&self, duration: Duration) -> Result<()> {
|
||||
|
|
Loading…
Add table
Reference in a new issue