Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Annotate cfg_error with format attribute
Format attributes help compilers to warn on format string misuses, like: cfg_error(cfg, user_defined_input) // potential security issue cfg_error(cfg, "foo %d", "bar") confuse.c:1246:20: warning: format string is not a string literal [-Wformat-nonliteral] vfprintf(stderr, fmt, ap); ^~~ Guard the annotation with __GNUC__, defined by GCC and Clang, which support the GNU extension of function format attributes.
- Loading branch information