mirror of
https://github.com/samba-team/samba.git
synced 2025-02-02 09:47:23 +03:00
Merge from HEAD - add PRINTF_ATTRIBUTE to a few more functions.
(This used to be commit 9e5297131cc53d7161aa74566f147b98e1c27aaa)
This commit is contained in:
parent
a63aa62bdd
commit
43059acb95
@ -1156,6 +1156,15 @@ int snprintf(char *,size_t ,const char *, ...) PRINTF_ATTRIBUTE(3,4);
|
||||
int asprintf(char **,const char *, ...) PRINTF_ATTRIBUTE(2,3);
|
||||
#endif
|
||||
|
||||
void sys_adminlog(int priority, const char *format_str, ...) PRINTF_ATTRIBUTE(2,3);
|
||||
|
||||
int pstr_sprintf(pstring s, const char *fmt, ...) PRINTF_ATTRIBUTE(2,3);
|
||||
int fstr_sprintf(fstring s, const char *fmt, ...) PRINTF_ATTRIBUTE(2,3);
|
||||
|
||||
int d_vfprintf(FILE *f, const char *format, va_list ap) PRINTF_ATTRIBUTE(2,0);
|
||||
|
||||
int smb_xvasprintf(char **ptr, const char *format, va_list ap) PRINTF_ATTRIBUTE(2,0);
|
||||
|
||||
/* we used to use these fns, but now we have good replacements
|
||||
for snprintf and vsnprintf */
|
||||
#define slprintf snprintf
|
||||
|
@ -44,4 +44,6 @@ extern XFILE *x_stdin, *x_stdout, *x_stderr;
|
||||
|
||||
#define x_getc(f) x_fgetc(f)
|
||||
|
||||
int x_vfprintf(XFILE *f, const char *format, va_list ap) PRINTF_ATTRIBUTE(2, 0);
|
||||
int x_fprintf(XFILE *f, const char *format, ...) PRINTF_ATTRIBUTE(2, 3);
|
||||
#endif /* _XFILE_H_ */
|
||||
|
@ -1233,7 +1233,7 @@ int sys_dup2(int oldfd, int newfd)
|
||||
Wrapper for Admin Logs.
|
||||
****************************************************************************/
|
||||
|
||||
void sys_adminlog(int priority, char *format_str, ...)
|
||||
void sys_adminlog(int priority, const char *format_str, ...)
|
||||
{
|
||||
va_list ap;
|
||||
int ret;
|
||||
|
Loading…
x
Reference in New Issue
Block a user