src/printf.c

changeset 805
26500fc24058
parent 693
494d9b20b99e
child 810
85859399a0cc
equal deleted inserted replaced
804:5136f2fc32ec 805:26500fc24058
32 #include <string.h> 32 #include <string.h>
33 33
34 #ifndef CX_PRINTF_SBO_SIZE 34 #ifndef CX_PRINTF_SBO_SIZE
35 #define CX_PRINTF_SBO_SIZE 512 35 #define CX_PRINTF_SBO_SIZE 512
36 #endif 36 #endif
37 unsigned const cx_printf_sbo_size = CX_PRINTF_SBO_SIZE;
37 38
38 int cx_fprintf( 39 int cx_fprintf(
39 void *stream, 40 void *stream,
40 cx_write_func wfc, 41 cx_write_func wfc,
41 char const *fmt, 42 char const *fmt,
83 CxAllocator const *allocator, 84 CxAllocator const *allocator,
84 char const *fmt, 85 char const *fmt,
85 ... 86 ...
86 ) { 87 ) {
87 va_list ap; 88 va_list ap;
88 cxmutstr ret;
89 va_start(ap, fmt); 89 va_start(ap, fmt);
90 ret = cx_vasprintf_a(allocator, fmt, ap); 90 cxmutstr ret = cx_vasprintf_a(allocator, fmt, ap);
91 va_end(ap); 91 va_end(ap);
92 return ret; 92 return ret;
93 } 93 }
94 94
95 cxmutstr cx_vasprintf_a( 95 cxmutstr cx_vasprintf_a(

mercurial