extern void *memchr(const void *, int, size_t);
extern void url_decode(char *str);
+/*
+ * NOTE: snprintf() returns the full length of the formatted string even if it
+ * couldn't fit in the supplied buffer.
+ * Use scnprintf() if you need the actual number of bytes (minus the \0)
+ */
int snprintf(char *, size_t, const char *, ...) __printflike(3, 4);
+int scnprintf(char *, size_t, const char *, ...) __printflike(3, 4);
/* sprintf() is being deprecated. Please use snprintf() instead. */
int sprintf(char *bufp, const char *, ...) __deprecated __printflike(2, 3);
extern int vprintf(const char *, va_list) __printflike(1, 0);
extern int vsnprintf(char *, size_t, const char *, va_list) __printflike(3, 0);
+extern int vscnprintf(char *, size_t, const char *, va_list) __printflike(3, 0);
#if XNU_KERNEL_PRIVATE
extern int vprintf_log_locked(const char *, va_list, bool addcr) __printflike(1, 0);