File tree Expand file tree Collapse file tree 2 files changed +2
-2
lines changed Expand file tree Collapse file tree 2 files changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -1090,7 +1090,7 @@ unsafe impl BufMut for BytesMut {
1090
1090
unsafe fn advance_mut ( & mut self , cnt : usize ) {
1091
1091
let remaining = self . cap - self . len ( ) ;
1092
1092
if cnt > remaining {
1093
- panic_advance ( cnt, remaining) ;
1093
+ super :: panic_advance ( cnt, remaining) ;
1094
1094
}
1095
1095
// Addition won't overflow since it is at most `self.cap`.
1096
1096
self . len = self . len ( ) + cnt;
Original file line number Diff line number Diff line change @@ -83,7 +83,7 @@ fn test_put_int_le_nbytes_overflow() {
83
83
}
84
84
85
85
#[ test]
86
- #[ should_panic( expected = "cannot advance" ) ]
86
+ #[ should_panic( expected = "advance out of bounds: the len is 8 but advancing by 12 " ) ]
87
87
fn test_vec_advance_mut ( ) {
88
88
// Verify fix for #354
89
89
let mut buf = Vec :: with_capacity ( 8 ) ;
You can’t perform that action at this time.
0 commit comments