diff options
author | Matthias Schiffer <mschiffer@universe-factory.net> | 2020-04-04 01:47:30 +0200 |
---|---|---|
committer | Matthias Schiffer <mschiffer@universe-factory.net> | 2020-04-04 01:47:30 +0200 |
commit | 52b498494534784c77bfa4a93706be40620ebd9a (patch) | |
tree | d8499f6bec9a452231c4fcfc4d05d6b450cebf1b /src/c/stdio.rs | |
parent | 9aae18d76454b01f07b177efafcc9867dfa7dff1 (diff) | |
download | neco-52b498494534784c77bfa4a93706be40620ebd9a.tar neco-52b498494534784c77bfa4a93706be40620ebd9a.zip |
Lots of changes
Diffstat (limited to 'src/c/stdio.rs')
-rw-r--r-- | src/c/stdio.rs | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/c/stdio.rs b/src/c/stdio.rs index aa824ed..c878f19 100644 --- a/src/c/stdio.rs +++ b/src/c/stdio.rs @@ -7,8 +7,12 @@ pub struct OStream { file: *mut libc::FILE } -pub fn stdout() -> OStream { - OStream { file: unsafe { posix::stdout } } +pub unsafe fn stdout() -> OStream { + OStream { file: posix::stdout } +} + +pub unsafe fn stderr() -> OStream { + OStream { file: posix::stderr } } impl OStream { |