about summary refs log tree commit diff
path: root/src
diff options
context:
space:
mode:
authorPatrick Walton <pcwalton@mimiga.net>2012-09-14 12:14:39 -0700
committerPatrick Walton <pcwalton@mimiga.net>2012-09-14 12:15:40 -0700
commit6a3756b0ba3dbab0c1957a7c829e09e9505c7574 (patch)
tree8817f655d85033924953d5ea02d9ef7609d0808f /src
parent044fbea416c8778ec8f653b93941dca6f2e9213e (diff)
downloadrust-6a3756b0ba3dbab0c1957a7c829e09e9505c7574.tar.gz
rust-6a3756b0ba3dbab0c1957a7c829e09e9505c7574.zip
test: Use vec::as_imm_buf in bug-2470-bounds-check-overflow.rs
Diffstat (limited to 'src')
-rw-r--r--src/test/run-fail/bug-2470-bounds-check-overflow.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/test/run-fail/bug-2470-bounds-check-overflow.rs b/src/test/run-fail/bug-2470-bounds-check-overflow.rs
index f3575963962..924b3dda149 100644
--- a/src/test/run-fail/bug-2470-bounds-check-overflow.rs
+++ b/src/test/run-fail/bug-2470-bounds-check-overflow.rs
@@ -9,7 +9,7 @@ fn main() {
     // huge).
 
     let x = ~[1u,2u,3u];
-    do vec::as_buf(x) |p, _len| {
+    do vec::as_imm_buf(x) |p, _len| {
         let base = p as uint;                     // base = 0x1230 say
         let idx = base / sys::size_of::<uint>();  // idx  = 0x0246 say
         error!("ov1 base = 0x%x", base);
@@ -21,4 +21,4 @@ fn main() {
         // This should fail.
         error!("ov1 0x%x",  x[idx]);
     }
-}
\ No newline at end of file
+}