MCPcopy Create free account
hub / github.com/NetHack/NetHack / xputs

Function xputs

sys/windows/consoletty.c:1205–1222  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1203}
1204
1205void
1206xputs(const char *s)
1207{
1208 int k;
1209 int slen = (int) strlen(s);
1210
1211 if (ttyDisplay)
1212 set_console_cursor(ttyDisplay->curx, ttyDisplay->cury);
1213
1214 if (s) {
1215 for (k = 0; k < slen && s[k]; ++k)
1216#ifndef VIRTUAL_TERMINAL_SEQUENCES
1217 xputc_core(s[k]);
1218#else
1219 xputc_core((int) s[k]);
1220#endif
1221 }
1222}
1223
1224/* xputc_core() and g_putch() are the only routines that actually place output.
1225 same signature as 'putchar()' with potential failure result ignored */

Callers 2

VA_DECLFunction · 0.70

Calls 2

set_console_cursorFunction · 0.85
xputc_coreFunction · 0.85

Tested by

no test coverage detected