diff options
Diffstat (limited to 'rust/kernel/uaccess.rs')
| -rw-r--r-- | rust/kernel/uaccess.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/rust/kernel/uaccess.rs b/rust/kernel/uaccess.rs index 7e4c953ba8a1..6d70edd8086a 100644 --- a/rust/kernel/uaccess.rs +++ b/rust/kernel/uaccess.rs @@ -288,7 +288,7 @@ impl UserSliceReader { // SAFETY: Since the call to `read_raw` was successful, so the next `len` bytes of the // vector have been initialized. - unsafe { buf.set_len(buf.len() + len) }; + unsafe { buf.inc_len(len) }; Ok(()) } } |