Add some printf format attributes suggested by gcc
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com> Reviewed-by: Jamey Sharp <jamey@minilop.net> Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
This commit is contained in:
parent
f68df9dfd2
commit
7801b3dcd6
|
@ -97,7 +97,7 @@ static const Mask SecurityClientMask = DixGetAttrAccess;
|
|||
* Writes the message to the log file if security logging is on.
|
||||
*/
|
||||
|
||||
static void
|
||||
static void _X_ATTRIBUTE_PRINTF(1,2)
|
||||
SecurityAudit(const char *format, ...)
|
||||
{
|
||||
va_list args;
|
||||
|
|
|
@ -232,7 +232,7 @@ extern _X_EXPORT void xf86SetDpi(ScrnInfoPtr pScrn, int x, int y);
|
|||
extern _X_EXPORT void xf86SetBlackWhitePixels(ScreenPtr pScreen);
|
||||
extern _X_EXPORT void xf86EnableDisableFBAccess(int scrnIndex, Bool enable);
|
||||
extern _X_EXPORT void xf86VDrvMsgVerb(int scrnIndex, MessageType type, int verb,
|
||||
const char *format, va_list args);
|
||||
const char *format, va_list args) _X_ATTRIBUTE_PRINTF(4,0);
|
||||
extern _X_EXPORT void xf86DrvMsgVerb(int scrnIndex, MessageType type, int verb,
|
||||
const char *format, ...) _X_ATTRIBUTE_PRINTF(4,5);
|
||||
extern _X_EXPORT void xf86DrvMsg(int scrnIndex, MessageType type, const char *format, ...)
|
||||
|
|
|
@ -552,7 +552,7 @@ xf86DriverlistFromCompile(void)
|
|||
* Print a READABLE ErrorMessage!!! All information that is
|
||||
* available is printed.
|
||||
*/
|
||||
static void
|
||||
static void _X_ATTRIBUTE_PRINTF(1,2)
|
||||
xf86ConfigError(const char *msg, ...)
|
||||
{
|
||||
va_list ap;
|
||||
|
|
|
@ -173,7 +173,7 @@ extern _X_EXPORT void xf86VIDrvMsgVerb(InputInfoPtr dev,
|
|||
MessageType type,
|
||||
int verb,
|
||||
const char *format,
|
||||
va_list args);
|
||||
va_list args) _X_ATTRIBUTE_PRINTF(4,0);
|
||||
|
||||
/* xf86Option.c */
|
||||
extern _X_EXPORT void xf86CollectInputOptions(InputInfoPtr pInfo, const char **defaultOpts);
|
||||
|
|
|
@ -95,8 +95,8 @@ int xf86getSubToken(char **comment);
|
|||
int xf86getSubTokenWithTab(char **comment, xf86ConfigSymTabRec *tab);
|
||||
void xf86unGetToken(int token);
|
||||
char *xf86tokenString(void);
|
||||
void xf86parseError(const char *format, ...);
|
||||
void xf86validationError(const char *format, ...);
|
||||
void xf86parseError(const char *format, ...) _X_ATTRIBUTE_PRINTF(1,2);
|
||||
void xf86validationError(const char *format, ...) _X_ATTRIBUTE_PRINTF(1,2);
|
||||
void xf86setSection(const char *section);
|
||||
int xf86getStringToken(xf86ConfigSymTabRec *tab);
|
||||
/* write.c */
|
||||
|
|
Loading…
Reference in New Issue