Replace ptr casts with typed cast() method
Replace type inferred raw pointer casts with .cast() method calls to make intent clearer. Signed-off-by: Manos Pitsidianakis <manos.pitsidianakis@linaro.org>
This commit is contained in:
parent
926ea9b1c8
commit
019e02b0f2
4 changed files with 7 additions and 5 deletions
|
|
@ -637,7 +637,8 @@ impl VhostUserBackendMut for VhostUserCanBackend {
|
|||
.config()
|
||||
.as_slice()
|
||||
.as_ptr()
|
||||
.offset(offset as isize) as *const _ as *const _,
|
||||
.offset(offset as isize)
|
||||
.cast::<u8>(),
|
||||
size as usize,
|
||||
)
|
||||
.to_vec()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue