Skip to content

Commit

Permalink
clippy fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
timokroeger committed Nov 29, 2024
1 parent 53b1307 commit df366db
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
3 changes: 1 addition & 2 deletions src/winapi/auto_start_entry.rs
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,6 @@ impl<'a> AutoStartEntry<'a> {
ptr::addr_of_mut!(path_buf_reg).cast(),
&mut path_len_reg,
) == 0;

if !key_exists {
return false;
}
Expand All @@ -64,7 +63,7 @@ impl<'a> AutoStartEntry<'a> {
// Add 1 to the length of the executable path to include the null
// terminator in the string comparison.
path_len_exe += 1;
return &path_buf_exe[..path_len_exe] == &path_buf_reg[..path_len_reg as usize];
path_buf_exe[..path_len_exe] == path_buf_reg[..path_len_reg as usize]
}
}

Expand Down
2 changes: 1 addition & 1 deletion src/winapi/keyboard.rs
Original file line number Diff line number Diff line change
Expand Up @@ -208,7 +208,7 @@ where

/// Sends a virtual key event.
pub fn send_key(key: KeyEvent) {
let _ = QUEUED_INPUTS.with(|queued_inputs| {
QUEUED_INPUTS.with(|queued_inputs| {
// There is a very small chance that windows re-enters the hook while
// we are moving out the data from the queue in `send_queued_inputs()`.
// We cannot do anything about that, do not send the key event.
Expand Down

0 comments on commit df366db

Please sign in to comment.