Fixed silly bug preventing building on rust-stable.

Fortune for collect's current commit: Small blessing − 小吉
safe-memfd
Avril 2 years ago
parent 1e207ca453
commit 9ecd0ea3d8
Signed by: flanchan
GPG Key ID: 284488987C31F630

@ -1,6 +1,6 @@
[package] [package]
name = "collect" name = "collect"
version = "1.0.0" version = "1.0.1"
description = "collect all of stdin until it is closed, then output it all to stdout" description = "collect all of stdin until it is closed, then output it all to stdout"
keywords = ["shell", "pipe", "utility", "unix", "linux"] keywords = ["shell", "pipe", "utility", "unix", "linux"]
authors = ["Avril <flanchan@cumallover.me>"] authors = ["Avril <flanchan@cumallover.me>"]

@ -10,13 +10,21 @@ use libc::{
}; };
//TODO: Make this a `bitflags` struct. //TODO: Make this a `bitflags` struct.
#[derive(Debug, Clone, PartialEq, Eq, Hash, PartialOrd, Ord, Copy, Default)] #[derive(Debug, Clone, PartialEq, Eq, Hash, PartialOrd, Ord, Copy)]
#[repr(i32)] #[repr(i32)]
pub enum MapProtection pub enum MapProtection
{ {
#[default]
None = PROT_NONE, None = PROT_NONE,
Read = PROT_READ, Read = PROT_READ,
Write = PROT_WRITE, Write = PROT_WRITE,
Execute = PROT_EXEC, Execute = PROT_EXEC,
} }
impl Default for MapProtection
{
#[inline(always)]
fn default() -> Self
{
Self::None
}
}

Loading…
Cancel
Save