Skip to content

Commit 95018ee

Browse files
committed
Auto merge of rust-lang#23372 - tamird:fix-ios-compilation, r=alexcrichton
r? @alexcrichton cc @vhbit
2 parents 54660fc + 04c947c commit 95018ee

File tree

2 files changed

+3
-13
lines changed

2 files changed

+3
-13
lines changed

src/libstd/sys/unix/backtrace.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,7 @@ pub fn write(w: &mut Write) -> io::Result<()> {
118118
// local, it still displays much nicer backtraces when a
119119
// couple of tasks panic simultaneously
120120
static LOCK: StaticMutex = MUTEX_INIT;
121-
let _g = unsafe { LOCK.lock() };
121+
let _g = LOCK.lock();
122122

123123
try!(writeln!(w, "stack backtrace:"));
124124
// 100 lines should be enough

src/libstd/sys/unix/tty.rs

+2-12
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,8 @@ pub struct TTY {
2323
}
2424

2525
#[cfg(any(target_os = "macos",
26+
target_os = "ios",
27+
target_os = "dragonfly",
2628
target_os = "freebsd",
2729
target_os = "bitrig",
2830
target_os = "openbsd"))]
@@ -54,12 +56,6 @@ impl TTY {
5456
Err(sys_common::unimpl())
5557
}
5658

57-
#[cfg(any(target_os = "linux",
58-
target_os = "android",
59-
target_os = "macos",
60-
target_os = "freebsd",
61-
target_os = "bitrig",
62-
target_os = "openbsd"))]
6359
pub fn get_winsize(&mut self) -> IoResult<(int, int)> {
6460
unsafe {
6561
#[repr(C)]
@@ -82,10 +78,4 @@ impl TTY {
8278
}
8379
}
8480
}
85-
86-
#[cfg(any(target_os = "ios",
87-
target_os = "dragonfly"))]
88-
pub fn get_winsize(&mut self) -> IoResult<(int, int)> {
89-
Err(sys_common::unimpl())
90-
}
9181
}

0 commit comments

Comments
 (0)