Skip to content

fix: govulncheck calls on C code#1228

Merged
another-rex merged 6 commits intogoogle:mainfrom
another-rex:fix-cgo-govulncheck
Sep 6, 2024
Merged

fix: govulncheck calls on C code#1228
another-rex merged 6 commits intogoogle:mainfrom
another-rex:fix-cgo-govulncheck

Conversation

@another-rex
Copy link
Copy Markdown
Collaborator

Fix CGO and govulncheck not working well together. govulncheck does not work on C code anyway, so disabling CGO doesn't change any capabilities.

Fixes #1220

@another-rex another-rex marked this pull request as draft September 6, 2024 00:56
@another-rex
Copy link
Copy Markdown
Collaborator Author

Actually, a better solution would be to set CGO_ENABLED=0 just before calling govulncheck itself in the code. I'll make that change.

@another-rex another-rex marked this pull request as ready for review September 6, 2024 01:03
@another-rex another-rex changed the title Fix cgo govulncheck fix: govulncheck calls on C code Sep 6, 2024
@codecov-commenter
Copy link
Copy Markdown

codecov-commenter commented Sep 6, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 67.65%. Comparing base (0bcec56) to head (e2f771c).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1228      +/-   ##
==========================================
- Coverage   67.65%   67.65%   -0.01%     
==========================================
  Files         174      174              
  Lines       16719    16721       +2     
==========================================
+ Hits        11312    11313       +1     
- Misses       4776     4777       +1     
  Partials      631      631              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@another-rex another-rex merged commit 61669db into google:main Sep 6, 2024
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.

[GitHub Action] scan fails on go projects that import C code

3 participants