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

checks: Clang-Format, part 4 #2712

Merged
merged 2 commits into from
Dec 22, 2022
Merged

checks: Clang-Format, part 4 #2712

merged 2 commits into from
Dec 22, 2022

Conversation

nilason
Copy link
Contributor

@nilason nilason commented Dec 20, 2022

Formatting following directories:

  • raster

raster/r.support/main.c Outdated Show resolved Hide resolved
Fix accidental typo
@@ -30,7 +28,7 @@
void (*get_row)(int, CELL *, int);

/* allocate entire map */
map = (CELL *) G_malloc(nrows * ncols * sizeof(CELL));
map = (CELL *)G_malloc(nrows * ncols * sizeof(CELL));

Check failure

Code scanning / CodeQL

Multiplication result converted to larger type

Multiplication result may overflow 'int' before it is converted to 'unsigned long'.
temp =
(unsigned char *)G_malloc(nrows * new_flag->leng *
sizeof(unsigned char));
temp = (unsigned char *)G_malloc(nrows * new_flag->leng *

Check failure

Code scanning / CodeQL

Multiplication result converted to larger type

Multiplication result may overflow 'int' before it is converted to 'unsigned long'.
Comment on lines +62 to +63
lines = (struct ReportLine *)G_malloc(
map1->edges.ncats * map2->edges.ncats * sizeof(struct ReportLine));

Check failure

Code scanning / CodeQL

Multiplication result converted to larger type

Multiplication result may overflow 'int' before it is converted to 'unsigned long'.
@nilason nilason merged commit b5a70ba into OSGeo:main Dec 22, 2022
@nilason nilason added this to the 8.3.0 milestone Dec 22, 2022
@nilason nilason added add to git-blame-ignore-revs Once merged, add to .git-blame-ignore-revs C Related code is in C labels Dec 22, 2022
@nilason nilason deleted the format_4 branch December 22, 2022 12:16
@nilason nilason removed the add to git-blame-ignore-revs Once merged, add to .git-blame-ignore-revs label Jan 2, 2023
ninsbl pushed a commit to ninsbl/grass that referenced this pull request Feb 17, 2023
@neteler neteler changed the title Clang-Format, part 4 checks: Clang-Format, part 4 Jun 6, 2023
neteler pushed a commit to nilason/grass that referenced this pull request Nov 7, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C Related code is in C
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants