rt::io: Use vec::reserve_additional

This commit is contained in:
blake2-ppc 2013-09-11 01:57:08 +02:00
parent 90dc9512ba
commit 6e538edea2

View File

@ -303,7 +303,7 @@ impl<T: Reader> ReaderUtil for T {
let start_len = buf.len(); let start_len = buf.len();
let mut total_read = 0; let mut total_read = 0;
buf.reserve_at_least(start_len + len); buf.reserve_additional(len);
vec::raw::set_len(buf, start_len + len); vec::raw::set_len(buf, start_len + len);
do (|| { do (|| {