summaryrefslogtreecommitdiff
path: root/source3/include
diff options
context:
space:
mode:
Diffstat (limited to 'source3/include')
-rw-r--r--source3/include/includes.h18
-rw-r--r--source3/include/proto.h4
2 files changed, 12 insertions, 10 deletions
diff --git a/source3/include/includes.h b/source3/include/includes.h
index a5fa555058..e2edb512ae 100644
--- a/source3/include/includes.h
+++ b/source3/include/includes.h
@@ -54,6 +54,13 @@
#endif
#endif
+/* use gcc attribute to check printf fns */
+#ifdef __GNUC__
+#define PRINTF_ATTRIBUTE(a1, a2) __attribute__ ((format (__printf__, a1, a2)))
+#else
+#define PRINTF_ATTRIBUTE(a1, a2)
+#endif
+
#ifdef RELIANTUNIX
/*
* <unistd.h> has to be included before any other to get
@@ -995,12 +1002,6 @@ extern int DEBUGLEVEL;
#endif
/* add varargs prototypes with printf checking */
-#ifdef __GNUC__
-#define PRINTF_ATTRIBUTE(a1, a2) __attribute__ ((format (__printf__, a1, a2)))
-#else
-#define PRINTF_ATTRIBUTE(a1, a2)
-#endif
-
int fdprintf(int , char *, ...) PRINTF_ATTRIBUTE(2,3);
#ifndef HAVE_SNPRINTF
int snprintf(char *,size_t ,const char *, ...) PRINTF_ATTRIBUTE(3,4);
@@ -1009,5 +1010,10 @@ int snprintf(char *,size_t ,const char *, ...) PRINTF_ATTRIBUTE(3,4);
int asprintf(char **,char *, ...) PRINTF_ATTRIBUTE(2,3);
#endif
+/* we used to use these fns, but now we have good replacements
+ for snprintf and vsnprintf */
+#define slprintf snprintf
+#define vslprintf vsnprintf
+
#endif /* _INCLUDES_H */
diff --git a/source3/include/proto.h b/source3/include/proto.h
index 62f8df2b03..12a63ca23c 100644
--- a/source3/include/proto.h
+++ b/source3/include/proto.h
@@ -213,10 +213,6 @@ void CatchSignal(int signum,void (*handler)(int ));
void CatchChild(void);
void CatchChildLeaveStatus(void);
-/*The following definitions come from lib/slprintf.c */
-
-int vslprintf(char *str, int n, char *format, va_list ap);
-
/*The following definitions come from lib/smbrun.c */
int smbrun(char *cmd, int *outfd);