diff options
| author | Huon Wilson <dbau.pp+github@gmail.com> | 2013-12-15 23:05:30 +1100 |
|---|---|---|
| committer | Huon Wilson <dbau.pp+github@gmail.com> | 2013-12-15 23:05:30 +1100 |
| commit | f53292f7ee7365fe50ac216efac438ff5569fd06 (patch) | |
| tree | 269b181beb06c1701eff224eaecfc1e4dd6d793d /src/libstd/io/native | |
| parent | 4f62c969f618463914b148d53bef1d0faeb2782f (diff) | |
| download | rust-f53292f7ee7365fe50ac216efac438ff5569fd06.tar.gz rust-f53292f7ee7365fe50ac216efac438ff5569fd06.zip | |
Move std::{str,vec}::raw::set_len to an unsafe method on Owned{Vector,Str}.
Diffstat (limited to 'src/libstd/io/native')
| -rw-r--r-- | src/libstd/io/native/file.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/libstd/io/native/file.rs b/src/libstd/io/native/file.rs index 7b5104657d9..4e1c6bf982a 100644 --- a/src/libstd/io/native/file.rs +++ b/src/libstd/io/native/file.rs @@ -706,7 +706,7 @@ pub fn readlink(p: &CString) -> IoResult<Path> { -1 => Err(super::last_error()), n => { assert!(n > 0); - unsafe { vec::raw::set_len(&mut buf, n as uint); } + unsafe { buf.set_len(n as uint); } Ok(Path::new(buf)) } } |
