xref: /plan9/sys/src/cmd/ssh2/esmprint.c (revision 63afb9a5d3f910047231762bcce0ee49fed3d07c)
1 #include <u.h>
2 #include <libc.h>
3 
4 char*
esmprint(char * fmt,...)5 esmprint(char *fmt, ...)
6 {
7 	va_list args;
8 	char *p;
9 
10 	va_start(args, fmt);
11 	p = vsmprint(fmt, args);
12 	va_end(args);
13 	if (p == nil)
14 		sysfatal("esmprint: out of memory: %r");
15 	setmalloctag(p, getcallerpc(&fmt));
16 	return p;
17 }
18