BIO_vsnprintf

Format a string into buf like vsnprintf, using OpenSSL's portable formatter.

Synopsis

Declared in <openssl/bio.h>

int
BIO_vsnprintf(
    char* buf,
    size_t n,
    char const* format,
    va_list args);

Return Value

Length that would have been written excluding the NUL, or -1 on encoding error.

Parameters

NameDescription
bufDestination buffer.
nCapacity of buf in bytes (including the trailing NUL).
formatprintf-style format string.
argsVariable-argument list for format.