diff --git a/tinyosc.c b/tinyosc.c index 3bfc616969..fb745c8c27 100644 --- a/tinyosc.c +++ b/tinyosc.c @@ -15,7 +15,6 @@ */ #include -#include #include #include #if _WIN32 @@ -173,7 +172,7 @@ void tosc_writeBundle(tosc_bundle *b, uint64_t timetag, char *buffer, const int } // always writes a multiple of 4 bytes -static uint32_t tosc_vwrite(char *buffer, const int len, +uint32_t tosc_vwrite(char *buffer, const int len, const char *address, const char *format, va_list ap) { memset(buffer, 0, len); // clear the buffer uint32_t i = (uint32_t) strlen(address); diff --git a/tinyosc.h b/tinyosc.h index c55d152317..7e7bb8a580 100644 --- a/tinyosc.h +++ b/tinyosc.h @@ -19,6 +19,7 @@ #include #include +#include #define TINYOSC_TIMETAG_IMMEDIATELY 1L @@ -160,6 +161,12 @@ uint32_t tosc_getBundleLength(tosc_bundle *b); uint32_t tosc_writeMessage(char *buffer, const int len, const char *address, const char *fmt, ...); +/** + * Like tosc_writeMessage, but allows passing in a va_list directly. + */ +uint32_t tosc_vwrite(char *buffer, const int len, + const char *address, const char *format, va_list ap); + /** * A convenience function to (non-destructively) print a buffer containing * an OSC message to stdout.