log_message() format parameter should be const char* #53
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Description
In
src/shared/log.hline 6 andsrc/shared/log.cline 13, thelog_message()function signature useschar* formatinstead ofconst char* format:This prevents passing string literals without a cast and generates warnings with
-Wwrite-stringsor-Wpedantic. The format string is not modified by the function.Location
src/shared/log.h:6,src/shared/log.c:13Suggested Fix
Change the signature to
const char* format(andconst char* message):Severity
Low
Category
Quality