diff --git a/build.rs b/build.rs
index 2a81bd3213..6aaa801efd 100644
--- a/build.rs
+++ b/build.rs
@@ -3,7 +3,6 @@ extern crate cc;
use std::{env, fs, fs::DirEntry, path::Path};
-
// include src/header directories that don't start with '_'
fn include_dir(d: &DirEntry) -> bool {
d.metadata().map(|m| m.is_dir()).unwrap_or(false)
@@ -15,10 +14,7 @@ fn include_dir(d: &DirEntry) -> bool {
fn get_target() -> String {
env::var("TARGET").unwrap_or(
- option_env!("TARGET").map_or(
- "x86_64-unknown-redox".to_string(),
- |x| x.to_string()
- )
+ option_env!("TARGET").map_or("x86_64-unknown-redox".to_string(), |x| x.to_string()),
)
}
@@ -68,7 +64,8 @@ fn main() {
let mut cc_builder = &mut cc::Build::new();
- cc_builder = cc_builder.flag("-nostdinc")
+ cc_builder = cc_builder
+ .flag("-nostdinc")
.flag("-nostdlib")
.include(&format!("{}/include", crate_dir))
.include(&format!("{}/target/include", crate_dir));
@@ -77,7 +74,8 @@ fn main() {
cc_builder = cc_builder.flag("-mno-outline-atomics")
}
- cc_builder.flag("-fno-stack-protector")
+ cc_builder
+ .flag("-fno-stack-protector")
.flag("-Wno-expansion-to-defined")
.files(
fs::read_dir("src/c")
diff --git a/posix-regex b/posix-regex
index 0d996efe5c..df45954609 160000
--- a/posix-regex
+++ b/posix-regex
@@ -1 +1 @@
-Subproject commit 0d996efe5cfe7ce181af35d8817ac4deae644d4a
+Subproject commit df45954609e219b11f108086b5861023a04126a7
diff --git a/src/header/grp/mod.rs b/src/header/grp/mod.rs
index 814bbaeb5b..e30a1d1557 100644
--- a/src/header/grp/mod.rs
+++ b/src/header/grp/mod.rs
@@ -3,15 +3,20 @@
use core::{
convert::{TryFrom, TryInto},
mem,
+ num::ParseIntError,
ops::{Deref, DerefMut},
pin::Pin,
primitive::str,
- ptr, slice, num::ParseIntError, str::Matches,
+ ptr, slice,
+ str::Matches,
};
use lazy_static::lazy_static;
-use alloc::{borrow::ToOwned, string::{String, FromUtf8Error}};
+use alloc::{
+ borrow::ToOwned,
+ string::{FromUtf8Error, String},
+};
use crate::{
c_str::CStr,
@@ -19,9 +24,9 @@ use crate::{
header::{errno, fcntl, string::strlen},
io,
io::{prelude::*, BufReader, Lines},
- platform::types::*,
platform,
- sync::Mutex
+ platform::types::*,
+ sync::Mutex,
};
use super::{errno::*, string::strncmp};
@@ -69,7 +74,9 @@ static mut GROUP: group = group {
gr_mem: ptr::null_mut(),
};
-lazy_static! { static ref LINE_READER: Mutex