Bug fixes for fcntl and o_cloexec

Add fcntl to schemes
Fix debug: hang
This commit is contained in:
Jeremy Soller
2017-04-19 21:56:09 -06:00
parent 40ff16e42d
commit efd64d55e1
19 changed files with 204 additions and 43 deletions
+1 -1
View File
@@ -239,7 +239,7 @@ impl Context {
pub fn get_file(&self, i: FileHandle) -> Option<File> {
let files = self.files.lock();
if i.into() < files.len() {
files[i.into()]
files[i.into()].clone()
} else {
None
}
+1 -1
View File
@@ -4,7 +4,7 @@ use scheme::SchemeId;
/// A file
//TODO: Close on exec
#[derive(Copy, Clone, Debug)]
#[derive(Clone, Debug)]
pub struct File {
/// The scheme that this file refers to
pub scheme: SchemeId,