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

error: format not a string literal and no format arguments [-Werror=format-security] #28

Open
GoogleCodeExporter opened this issue Jun 23, 2015 · 0 comments

Comments

@GoogleCodeExporter
Copy link

What steps will reproduce the problem?
1. add -Werror=format-security to CFLAGS
2. build
3. watch it break:

DEBUG: fterr.c: In function 'fterr_info':
DEBUG: fterr.c:115:5: error: format not a string literal and no format 
arguments [-Werror=format-security]
DEBUG:      syslog(LOG_INFO, buf);
DEBUG:      ^
DEBUG: fterr.c: In function 'fterr_err':
DEBUG: fterr.c:137:5: error: format not a string literal and no format 
arguments [-Werror=format-security]
DEBUG:      syslog(LOG_INFO, buf2);
DEBUG:      ^
DEBUG: fterr.c: In function 'fterr_errx':
DEBUG: fterr.c:162:5: error: format not a string literal and no format 
arguments [-Werror=format-security]
DEBUG:      syslog(LOG_INFO, buf);
DEBUG:      ^
DEBUG: fterr.c: In function 'fterr_warnx':
DEBUG: fterr.c:186:5: error: format not a string literal and no format 
arguments [-Werror=format-security]
DEBUG:      syslog(LOG_INFO, buf);
DEBUG:      ^
DEBUG: fterr.c: In function 'fterr_warn':
DEBUG: fterr.c:208:5: error: format not a string literal and no format 
arguments [-Werror=format-security]
DEBUG:      syslog(LOG_INFO, buf2);
DEBUG:      ^
DEBUG: cc1: some warnings being treated as errors


What is the expected output? What do you see instead?

Should just build.

What version of the product are you using? On what operating system?

0.68.5 on Fedora/rawhide

Please provide any additional information below.

Fedora is using -Werror=format-security in CFLAGS and flow-tools fails to 
build. Attached patch fixes it.

Original issue reported on code.google.com by [email protected] on 24 Jun 2014 at 6:30

Attachments:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant