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

Fix build warning due to string truncation #308

Merged
merged 1 commit into from
Nov 18, 2020

Conversation

stauffer-garmin
Copy link
Contributor

strncpy gives an "output may be truncated" warning in newer versions of
GCC due to *pBuf being larger (100) than *pHeaderStr (16). Use memcpy
and explicitly null-terminate the target string.

This fixes issue #306.

strncpy gives an "output may be truncated" warning in newer versions of
GCC due to *pBuf being larger (100) than *pHeaderStr (16).  Use memcpy
and explicitly null-terminate the target string.
@coveralls
Copy link

Coverage Status

Coverage remained the same at 100.0% when pulling 0ae04a6 on stauffer-garmin:master into adb7e7c on SRombauts:master.

@SRombauts SRombauts self-assigned this Nov 18, 2020
@SRombauts
Copy link
Owner

Looking good, thank you!

@SRombauts SRombauts merged commit 721b245 into SRombauts:master Nov 18, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants