xmalloc: export xvasprintf()

This commit is contained in:
Daniel Eklöf 2021-05-07 16:41:02 +02:00
parent cda55d7de4
commit 7af475098b
No known key found for this signature in database
GPG key ID: 5BBD4992C116573F
2 changed files with 3 additions and 1 deletions

View file

@ -71,7 +71,7 @@ xvasprintf_(char **strp, const char *format, va_list ap)
return vsnprintf(*strp, n + 1, format, ap);
}
static VPRINTF(1) char *
char *
xvasprintf(const char *format, va_list ap)
{
char *str;

View file

@ -1,5 +1,6 @@
#pragma once
#include <stdarg.h>
#include <stddef.h>
#include <wchar.h>
#include "macros.h"
@ -10,4 +11,5 @@ void *xrealloc(void *ptr, size_t size);
char *xstrdup(const char *str) XSTRDUP;
char *xstrndup(const char *str, size_t n) XSTRDUP;
char *xasprintf(const char *format, ...) PRINTF(1) XMALLOC;
char *xvasprintf(const char *format, va_list va) VPRINTF(1) XMALLOC;
wchar_t *xwcsdup(const wchar_t *str) XSTRDUP;