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

add linter for c code #3350

Open
michaellilltokiwa opened this issue Jul 10, 2024 · 0 comments
Open

add linter for c code #3350

michaellilltokiwa opened this issue Jul 10, 2024 · 0 comments
Labels
C backend related to the C backend enhancement New feature or request

Comments

@michaellilltokiwa
Copy link
Member

michaellilltokiwa commented Jul 10, 2024

e.g. clang-tidy include/posix.c
gives some useful suggestions:

/home/not_synced/fuzion/include/posix.c:98:5: warning: Call to function 'strcpy' is insecure as it does not provide bounding of the memory buffer. Replace unbounded copy functions with analogous functions that support length arguments such as 'strlcpy'. CWE-119 [clang-analyzer-security.insecureAPI.strcpy]
    strcpy(dup, d->d_name);
    ^~~~~~
@michaellilltokiwa michaellilltokiwa added enhancement New feature or request C backend related to the C backend labels Jul 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C backend related to the C backend enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant