#ffi #shutdown #stdlib #std

shutdown_hooks

Shutdown hooks for Rust. Currently a friendly wrapper around atexit, will eventually allow you to remove hooks

5 releases

Uses old Rust 2015

0.1.0 Jul 29, 2015
0.0.3 Jul 29, 2015
0.0.2 Jul 29, 2015
0.0.1 Jul 29, 2015
0.0.0 Jul 29, 2015

#1175 in Asynchronous

Download history 10298/week @ 2023-05-18 8781/week @ 2023-05-25 14606/week @ 2023-06-01 14663/week @ 2023-06-08 14954/week @ 2023-06-15 15745/week @ 2023-06-22 15852/week @ 2023-06-29 15227/week @ 2023-07-06 15724/week @ 2023-07-13 8201/week @ 2023-07-20 7990/week @ 2023-07-27 10166/week @ 2023-08-03 6517/week @ 2023-08-10 6452/week @ 2023-08-17 7864/week @ 2023-08-24 6025/week @ 2023-08-31

28,377 downloads per month
Used in 4 crates (2 directly)

MIT license

3KB

shutdown_hooks Build Status Crates.io

Shutdown hook functionality for Rust. Basically a wrapper around atexit for now

An unspecified future release will feature the ability to remove shutdown hooks

#Notes

So far, I have successfully tested an eight-second long shutdown hook under Windows. I haven't tested any longer than that, but you should be fine. If not, you would have faced the same issue with atexit anyway :)


lib.rs:

Provides access to shutdown hooks

Currently, only adding new hooks is supported.

An unspecified future release will have a collection of hooks and have the ability to remove them

No runtime deps