Skip to content

More newrt file io work #9235

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 21 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
21 commits
Select commit Hold shift + click to select a range
af65057
std/rt: in-progress file io work
olsonjeffery Aug 26, 2013
055488d
merge cleanup
olsonjeffery Sep 3, 2013
b49fc4c
std: adding file::{stat,mkdir,rmdir}, FileInfo and FileReader/FileWriter
olsonjeffery Sep 14, 2013
daf4974
std: win32 os::env() str parsing to str::raw::from_c_multistring + test
olsonjeffery Sep 14, 2013
71c7798
std: clean up Dir/FileInfo inheritence and flesh out Dir Info
olsonjeffery Sep 15, 2013
6318288
std: more work on from_c_multistring.. let it take an optional len param
olsonjeffery Sep 16, 2013
25b4d8c
std: expose more stat info
olsonjeffery Sep 16, 2013
bf399d5
std: bind uv_fs_readdir(), flesh out DirectoryInfo and docs/cleanup
olsonjeffery Sep 16, 2013
e741449
std: unignore some file io tests that work on windows, now
olsonjeffery Sep 16, 2013
52840a5
std: correctly pass STDOUT in to naive_print test fn
olsonjeffery Sep 16, 2013
e9acdd9
std: generlize & move io::file::suppressed_stat to io::ignore_io_error
olsonjeffery Sep 17, 2013
a87ff60
std: remove impl'd/commented-out fstat signatures
olsonjeffery Sep 17, 2013
60ba170
std: FsRequest.req_boilerplate() be &mut self
olsonjeffery Sep 17, 2013
d3ed9a9
std: lots of docs for std::rt::io::file
olsonjeffery Sep 17, 2013
56c87ff
std: minor cleanup in some io_error descs in io::file
olsonjeffery Sep 17, 2013
95ef1f5
std: docstring fixes in io::file
olsonjeffery Sep 17, 2013
c0ec40f
std: merge conflict cleanup from std::str
olsonjeffery Sep 17, 2013
3067ee6
std: remove RtioStream
olsonjeffery Sep 17, 2013
5d9932f
std: fix win32 build error in os::env()
olsonjeffery Sep 17, 2013
a5275ff
std: whitespace clean up io::file docs
olsonjeffery Sep 17, 2013
70152ff
std: fix win32 build issue re: multistring parsing
olsonjeffery Sep 17, 2013
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 1 addition & 10 deletions src/libstd/os.rs
Original file line number Diff line number Diff line change
Expand Up @@ -196,16 +196,7 @@ pub fn env() -> ~[(~str,~str)] {
if (ch as uint == 0) {
fail!("os::env() failure getting env string from OS: %s", os::last_os_error());
}
let mut curr_ptr: uint = ch as uint;
let mut result = ~[];
while(*(curr_ptr as *libc::c_char) != 0 as libc::c_char) {
let env_pair = str::raw::from_c_str(
curr_ptr as *libc::c_char);
result.push(env_pair);
curr_ptr +=
libc::strlen(curr_ptr as *libc::c_char) as uint
+ 1;
}
let result = str::raw::from_c_multistring(ch as *libc::c_char, None);
FreeEnvironmentStringsA(ch);
result
}
Expand Down
Loading