rust/tests/ui/read_zero_byte_vec.stderr

65 lines
1.8 KiB
Plaintext
Raw Normal View History

2022-06-06 08:48:05 -05:00
error: reading zero byte data to `Vec`
--> $DIR/read_zero_byte_vec.rs:21:5
2022-06-06 08:48:05 -05:00
|
LL | f.read_exact(&mut data).unwrap();
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `data.resize(20, 0); f.read_exact(&mut data).unwrap();`
|
= note: `-D clippy::read-zero-byte-vec` implied by `-D warnings`
error: reading zero byte data to `Vec`
--> $DIR/read_zero_byte_vec.rs:27:5
2022-06-06 08:48:05 -05:00
|
LL | f.read_exact(&mut data2)?;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `data2.resize(cap, 0); f.read_exact(&mut data2)?;`
error: reading zero byte data to `Vec`
--> $DIR/read_zero_byte_vec.rs:32:5
2022-06-06 08:48:05 -05:00
|
LL | f.read_exact(&mut data3)?;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^
error: reading zero byte data to `Vec`
--> $DIR/read_zero_byte_vec.rs:37:5
2022-06-06 08:48:05 -05:00
|
LL | let _ = f.read(&mut data4)?;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
error: reading zero byte data to `Vec`
--> $DIR/read_zero_byte_vec.rs:43:9
2022-06-06 08:48:05 -05:00
|
LL | f.read(&mut data5)
| ^^^^^^^^^^^^^^^^^^
error: reading zero byte data to `Vec`
--> $DIR/read_zero_byte_vec.rs:50:9
2022-06-06 08:48:05 -05:00
|
LL | f.read(&mut data6)
| ^^^^^^^^^^^^^^^^^^
error: reading zero byte data to `Vec`
--> $DIR/read_zero_byte_vec.rs:81:5
2022-06-06 08:48:05 -05:00
|
LL | r.read(&mut data).await.unwrap();
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
error: reading zero byte data to `Vec`
--> $DIR/read_zero_byte_vec.rs:86:5
2022-06-06 08:48:05 -05:00
|
LL | r.read_exact(&mut data2).await.unwrap();
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
error: reading zero byte data to `Vec`
--> $DIR/read_zero_byte_vec.rs:93:5
2022-06-06 08:48:05 -05:00
|
LL | r.read(&mut data).await.unwrap();
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
error: reading zero byte data to `Vec`
--> $DIR/read_zero_byte_vec.rs:98:5
2022-06-06 08:48:05 -05:00
|
LL | r.read_exact(&mut data2).await.unwrap();
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
error: aborting due to 10 previous errors