File tree Expand file tree Collapse file tree 2 files changed +13
-0
lines changed Expand file tree Collapse file tree 2 files changed +13
-0
lines changed Original file line number Diff line number Diff line change @@ -9,6 +9,11 @@ This project adheres to [Semantic Versioning](https://semver.org/).
9
9
- Fix ` SigSet ` incorrect implementation of ` Eq ` , ` PartialEq ` and ` Hash `
10
10
([ #1946 ] ( https://github.com/nix-rust/nix/pull/1946 ) )
11
11
12
+ ### Added
13
+
14
+ - Added ` impl From<Signal> for SigSet ` .
15
+ ([ #1959 ] ( https://github.com/nix-rust/nix/pull/1959 ) )
16
+
12
17
### Changed
13
18
14
19
- The following APIs now take an implementation of ` AsFd ` rather than a
Original file line number Diff line number Diff line change @@ -604,6 +604,14 @@ impl SigSet {
604
604
}
605
605
}
606
606
607
+ impl From <Signal > for SigSet {
608
+ fn from( signal: Signal ) -> SigSet {
609
+ let mut sigset = SigSet :: empty( ) ;
610
+ sigset. add( signal) ;
611
+ sigset
612
+ }
613
+ }
614
+
607
615
impl AsRef <libc:: sigset_t> for SigSet {
608
616
fn as_ref( & self ) -> & libc:: sigset_t {
609
617
& self . sigset
You can’t perform that action at this time.
0 commit comments