input: replace fallible integer cast with try_into
casting usize as i32 might wrap around in 32-bit targets, we don't target them, but clippy complains. Signed-off-by: Manos Pitsidianakis <manos.pitsidianakis@linaro.org>
This commit is contained in:
parent
019e02b0f2
commit
735bbdbb21
1 changed files with 1 additions and 1 deletions
|
|
@ -64,7 +64,7 @@ macro_rules! ioctl_read_buf {
|
|||
for item in data.iter_mut() {
|
||||
*item = $nr as u8;
|
||||
}
|
||||
Ok(data.len() as i32)
|
||||
Ok(data.len().try_into().unwrap())
|
||||
}
|
||||
)
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue