Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

rust: fix clippy 1.85 precedence warnings #12647

Closed
wants to merge 1 commit into from

Conversation

catenacyber
Copy link
Contributor

Link to ticket: https://redmine.openinfosecfoundation.org/issues/
None, just clippy fixes

Describe changes:

  • fix new clippy warning about precedence

warning: operator precedence can trip the unwary
   --> src/jsonbuilder.rs:781:36
    |
781 |                 buf[offset] = HEX[(x >> 4 & 0xf) as usize];
    |                                    ^^^^^^^^^^^^ help: consider parenthesizing your expression: `(x >> 4) & 0xf`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#precedence
    = note: `#[warn(clippy::precedence)]` on by default
Copy link

codecov bot commented Feb 21, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 80.78%. Comparing base (d61f36c) to head (86eb502).
Report is 11 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master   #12647      +/-   ##
==========================================
+ Coverage   80.76%   80.78%   +0.01%     
==========================================
  Files         932      932              
  Lines      259381   259381              
==========================================
+ Hits       209484   209535      +51     
+ Misses      49897    49846      -51     
Flag Coverage Δ
fuzzcorpus 57.01% <100.00%> (+<0.01%) ⬆️
livemode 19.36% <0.00%> (+<0.01%) ⬆️
pcap 44.18% <100.00%> (+0.02%) ⬆️
suricata-verify 63.51% <100.00%> (+0.02%) ⬆️
unittests 58.33% <40.00%> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

@victorjulien
Copy link
Member

Merged in #12653, thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants