Skip to content

Conversation

@softins
Copy link
Member

@softins softins commented Jan 27, 2022

Short description of changes

Improve buffer offset calculation to avoid multiplication overflow warnings and improve efficiency

Context: Fixes an issue?

#2292 did not fix the CodeQL warnings, so this is an alternative and better approach.

Does this change need documentation? What needs to be documented and how?

No

Status of this Pull Request

Ready and should work.

What is missing until this pull request can be merged?

Smoke test with a server or client. Client built on Pi works fine.

Checklist

  • I've verified that this Pull Request follows the general code principles
  • I tested my code and it does what I want
  • My code follows the style guide
  • I waited some time after this Pull Request was opened and all GitHub checks completed without errors.
  • I've filled all the content above

@softins softins requested a review from hoffie January 27, 2022 13:18
@softins softins added this to the Release 3.8.2 milestone Jan 27, 2022
This is more efficient, and should avoid the CodeQL warnings
about multiplication overflow within array indices or vector offsets
in buffer.cpp and server.cpp

Replaces the changes that were done in jamulussoftware#2292
@softins softins force-pushed the codeql-multiply-v2 branch from f61991b to 8d656ed Compare January 27, 2022 17:01
Copy link
Collaborator

@pljones pljones left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It looks nicer than what was there...

Copy link
Member

@ann0see ann0see left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See below.

@ann0see ann0see merged commit 2725e6d into jamulussoftware:master Jan 27, 2022
ann0see added a commit to hoffie/jamulus that referenced this pull request Jan 27, 2022
@softins softins deleted the codeql-multiply-v2 branch August 31, 2023 15:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Triage

Development

Successfully merging this pull request may close these issues.

3 participants