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 several C errors #5

Merged
merged 2 commits into from
Oct 15, 2024
Merged

Fix several C errors #5

merged 2 commits into from
Oct 15, 2024

Conversation

klmr
Copy link
Contributor

@klmr klmr commented Oct 15, 2024

  • Rprintf cannot have a non-literal as its first argument; this used to work simply because compiler diagnostics were not good enough, but some R configurations compile with -Werror=format-security, and this code then causes an error.
  • [v]sprintf is blocked by FORTIFY_SOURCE. Fixing it should be as easy as replacing the relevant calls by [v]snprintf.

/cc @banfai

`Rprintf` cannot have a non-literal as its first argument; this used to
work simply because compiler diagnostics were not good enough, but some
R configurations compile with `-Werror=format-security`, and this code
then causes an error.
@klmr klmr changed the title Fix Rprintf calls with non-literals Fix several C errors Oct 15, 2024
@Accio Accio merged commit 7bb49d4 into master Oct 15, 2024
0 of 4 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.

2 participants