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

style and compilation fixes for src/enjoy.c #4

Merged
merged 2 commits into from Mar 24, 2022
Merged

style and compilation fixes for src/enjoy.c #4

merged 2 commits into from Mar 24, 2022

Conversation

maribu
Copy link
Contributor

@maribu maribu commented Mar 23, 2022

  • drop same trailing whitespace in src/enjoy.c
  • consistently use 4 spaces for indent (replace some instances where 3 spaces were used instead)
  • fix incorrect use of printf format specifier to fix
enjoy.c:413:55: warning: format '%ld' expects argument of type 'long int', but argument 3 has type 'size_t' {aka 'unsigned int'} [-Wformat=]
  413 |                     sprintf(axis_as_mouse_key, "axis%ld_as_mouse", axis);
      |                                                     ~~^            ~~~~
      |                                                       |            |
      |                                                       long int     size_t {aka unsigned int}
      |                                                     %d

- drop trailing whitespace
- reformatted a function that used an indent of 3 spaces instead of 4
  like the rest of the file
@maribu maribu changed the title style and compilation fixes style and compilation fixes for src/enjoy.c Mar 23, 2022
`%ld` is the format specifier for long. The correct format specifier
for `size_t` is `%zu`.
@cjacker cjacker merged commit 9faab22 into cjacker:main Mar 24, 2022
@maribu maribu deleted the src/enjoy.c branch March 24, 2022 13:11
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.

None yet

2 participants