#shutdown #stdlib #ffi #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

#19 in #stdlib

Download history 9959/week @ 2023-12-15 9642/week @ 2023-12-22 11347/week @ 2023-12-29 10224/week @ 2024-01-05 10714/week @ 2024-01-12 11589/week @ 2024-01-19 10319/week @ 2024-01-26 11654/week @ 2024-02-02 14212/week @ 2024-02-09 6768/week @ 2024-02-16 8475/week @ 2024-02-23 10900/week @ 2024-03-01 11413/week @ 2024-03-08 12752/week @ 2024-03-15 15245/week @ 2024-03-22 13199/week @ 2024-03-29

54,372 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