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

Function sfi_char

src/sfbase.c:264–287  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

262}
263
264void
265sfi_char(NHFILE *nhfp, char *d_char, const char *myname, int cnt)
266{
267 if (nhfp->structlevel) {
268 (*sfiprocs[nhfp->fnidx].fn.sf_char)(nhfp, d_char, myname, cnt);
269 } else {
270 int save_mode = nhfp->mode;
271
272 nhfp->mode &= ~(CONVERTING | UNCONVERTING);
273 nhfp->mode |= TURN_OFF_LOGGING;
274 (*sfiflprocs[nhfp->fnidx].fn_x.sf_char)(nhfp, d_char, myname, cnt);
275 nhfp->mode = save_mode;
276 }
277 if (!nhfp->eof) {
278 if ((((nhfp->mode & CONVERTING) != 0)
279 || ((nhfp->mode & UNCONVERTING) != 0))
280 && nhfp->nhfpconvert) {
281 sfo_char(nhfp->nhfpconvert, d_char, myname, cnt);
282 }
283 if (nhfp->fplog)
284 sf_log(nhfp, myname, sizeof(char), cnt,
285 Sfvalue_char(d_char, cnt));
286 }
287}
288
289void
290sfo_genericptr(NHFILE *nhfp, void **d_genericptr, const char *myname)

Callers

nothing calls this directly

Calls 2

sfo_charFunction · 0.85
sf_logFunction · 0.85

Tested by

no test coverage detected