From 1551287b1bd029b21e50c3916c8c51d259851478 Mon Sep 17 00:00:00 2001 From: Alex Crichton Date: Wed, 17 Sep 2014 07:24:59 -0700 Subject: [PATCH] Update to master --- src/gz.rs | 4 ++-- src/raw.rs | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/gz.rs b/src/gz.rs index 0869bf1ac..04396439a 100644 --- a/src/gz.rs +++ b/src/gz.rs @@ -218,7 +218,7 @@ impl EncoderWriter { impl Writer for EncoderWriter { fn write(&mut self, buf: &[u8]) -> IoResult<()> { if self.header.len() != 0 { - try!(self.inner.inner.get_mut_ref().write(self.header.as_slice())); + try!(self.inner.inner.as_mut().unwrap().write(self.header.as_slice())); self.header.truncate(0); } try!(self.inner.write(buf)); @@ -288,7 +288,7 @@ impl Reader for EncoderReader { } else if self.pos < self.header.len() { amt += copy(into, self.header.as_slice(), &mut self.pos); if amt == into.len() { return Ok(amt) } - let tmp = into; into = tmp.mut_slice_from(amt); + let tmp = into; into = tmp.slice_from_mut(amt); } match self.inner.read(into) { Ok(a) => Ok(amt + a), diff --git a/src/raw.rs b/src/raw.rs index 3cd0ae87c..d19cf5547 100644 --- a/src/raw.rs +++ b/src/raw.rs @@ -201,7 +201,7 @@ impl Stream { self.next_in = buf.slice_from(*pos).as_ptr(); self.avail_in = (buf.len() - *pos) as libc::c_uint; - self.next_out = into.mut_slice_from(read).as_mut_ptr(); + self.next_out = into.slice_from_mut(read).as_mut_ptr(); self.avail_out = (into.len() - read) as libc::c_uint; let before_out = self.total_out; @@ -239,7 +239,7 @@ impl Stream { self.next_in = buf.as_ptr(); self.avail_in = buf.len() as libc::c_uint; let cur_len = into.len(); - self.next_out = into.mut_slice_from(cur_len).as_mut_ptr(); + self.next_out = into.slice_from_mut(cur_len).as_mut_ptr(); self.avail_out = (cap - cur_len) as libc::c_uint; let before_out = self.total_out;