| Summary: | cups-filters: pdfOut_printf format string mismatches | ||
|---|---|---|---|
| Product: | Red Hat Enterprise Linux 7 | Reporter: | Florian Weimer <fweimer> |
| Component: | cups-filters | Assignee: | Tim Waugh <twaugh> |
| Status: | CLOSED CURRENTRELEASE | QA Contact: | Petr Sklenar <psklenar> |
| Severity: | unspecified | Docs Contact: | |
| Priority: | low | ||
| Version: | 7.0 | CC: | jscotka |
| Target Milestone: | rc | ||
| Target Release: | --- | ||
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
| Whiteboard: | |||
| Fixed In Version: | cups-filters-1.0.35-9.el7 | Doc Type: | Bug Fix |
| Doc Text: | Story Points: | --- | |
| Clone Of: | Environment: | ||
| Last Closed: | 2014-05-27 14:22:48 UTC | Type: | Bug |
| Regression: | --- | Mount Type: | --- |
| Documentation: | --- | CRM: | |
| Verified Versions: | Category: | --- | |
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
| Cloudforms Team: | --- | Target Upstream Version: | |
| Bug Depends On: | |||
| Bug Blocks: | 1002935 | ||
Similarly, applying this to fontembed/dynstring.h
int dyn_printf(DYN_STRING *ds,const char *fmt,...)
__attribute__((format(printf, 2, 3)));
yields:
fontembed/embed_sfnt.c:522:20: warning: invalid conversion specifier '!' [-Wformat-invalid-specifier]
dyn_printf(&ds,"%!PS-TrueTypeFont-%d-%d\n",
~^
fontembed/embed_sfnt.c:522:41: warning: more '%' conversions than data arguments [-Wformat]
dyn_printf(&ds,"%!PS-TrueTypeFont-%d-%d\n",
~^
That's equally harmless.
Filed as Fedora bug #1014093. |
After adding this void pdfOut_printf(pdfOut *pdf,const char *fmt,...) __attribute__((format(printf, 2, 3))); to filter/pdfutils.h, I get these format string mismatches: filter/pdfutils.c:246:23: warning: format specifies type 'int' but the argument has type 'long' [-Wformat] pdf->xref[iA]); ^~~~~~~~~~~~~ filter/pdfutils.c:352:29: warning: format specifies type 'int' but the argument has type 'long' [-Wformat] ,l0_obj,streamsize); ^~~~~~~~~~ filter/texttopdf.c:255:29: warning: format specifies type 'int' but the argument has type 'long' [-Wformat] len_obj,size); ^~~~ This looks harmless (int is promoted to long in varargs anyway).