Skip to content

Fix Implicit narrowing conversion in compound assignment#1717

Merged
laeubi merged 1 commit intoeclipse-pde:masterfrom
laeubi:Implicit_narrowing_conversion_in_compound_assignment
Apr 8, 2025
Merged

Fix Implicit narrowing conversion in compound assignment#1717
laeubi merged 1 commit intoeclipse-pde:masterfrom
laeubi:Implicit_narrowing_conversion_in_compound_assignment

Conversation

@laeubi
Copy link
Copy Markdown
Contributor

@laeubi laeubi commented Apr 7, 2025

Currently we add a long to an int this can result in information loss and numeric errors such as overflows.

As we only skip an integer amount of bytes the result can also only be an int of bytes skipped, adding an explicit cast makes the security scanner happy here.

@github-actions
Copy link
Copy Markdown

github-actions Bot commented Apr 7, 2025

Test Results

   285 files     285 suites   51m 1s ⏱️
 3 608 tests  3 532 ✅  76 💤 0 ❌
11 016 runs  10 785 ✅ 231 💤 0 ❌

Results for commit 468e8b7.

♻️ This comment has been updated with latest results.

Currently we add a long to an int this can result in information loss
and numeric errors such as overflows.

As we only skip an integer amount of bytes the result can also only be
an int of bytes skipped, adding an explicit cast makes the security
scanner happy here.
@laeubi laeubi force-pushed the Implicit_narrowing_conversion_in_compound_assignment branch from 6e9bafb to 468e8b7 Compare April 8, 2025 10:23
@laeubi laeubi merged commit b2b12f1 into eclipse-pde:master Apr 8, 2025
19 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant