fix: address PR #98 review feedback
All checks were successful
CI Code / Check spelling (pull_request) Successful in 23s
CI Code / Check coding style (pull_request) Successful in 34s
CI Code / Code Coverage (pull_request) Successful in 4m48s
CI Code / Linux (ubuntu) (pull_request) Successful in 6m14s
CI Code / Linux (debian) (pull_request) Successful in 6m15s
CI Code / Linux (arch) (pull_request) Successful in 6m35s

- check-cwe134.sh: match gchar* in addition to char* in variadic pattern
- rosterwin.c: merge duplicated if/else into single condition
- omemo.c: remove unnecessary scope block and goto, use early return
This commit is contained in:
2026-03-07 13:08:07 +03:00
parent 4ef3bc8e46
commit d081993c90
3 changed files with 25 additions and 40 deletions

View File

@@ -72,13 +72,13 @@ echo ""
KNOWN_RE=$(IFS="|"; echo "${REQUIRED_ATTRIBUTED[*]}")
# Find variadic declarations with a const char* parameter followed by ...)
# Find variadic declarations with a const char* / gchar* parameter followed by ...)
# that do NOT have a format attribute on the preceding line
NEW_ISSUES=$(grep -B1 -rn --include="*.h" \
'const char\s*\*.*,\s*\.\.\.)' "$DIR" 2>/dev/null \
'const g\?char\s*\*.*,\s*\.\.\.)' "$DIR" 2>/dev/null \
| awk '
/format\(printf|G_GNUC_PRINTF/ { skip=1; next }
/const char.*,.*\.\.\.\)/ {
/const g?char.*,.*\.\.\.\)/ {
if (skip) { skip=0; next }
print
}