ref: a2c587e7d7a8b72a7ef9afcd119d8cfb20076b54
dir: /seprint.c/
#include "platform.h" char * seprint(char *buf, char *e, char *fmt, ...) { va_list a; int n, m; if(e <= buf) return e; va_start(a, fmt); m = e-buf-1; n = vsnprintf(buf, m, fmt, a); va_end(a); return buf + (n < m ? n : m); }