MCPcopy Index your code
hub / github.com/NetHack/NetHack / delete_levelfile

Function delete_levelfile

src/files.c:718–730  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

716}
717
718void
719delete_levelfile(int lev)
720{
721 /*
722 * Level 0 might be created by port specific code that doesn't
723 * call create_levfile(), so always assume that it exists.
724 */
725 if (lev == 0 || (svl.level_info[lev].flags & LFILE_EXISTS)) {
726 set_levelfile_name(gl.lock, lev);
727 (void) unlink(fqname(gl.lock, LEVELPREFIX, 0));
728 svl.level_info[lev].flags &= ~LFILE_EXISTS;
729 }
730}
731
732void
733clearlocks(void)

Callers 11

mainFunction · 0.85
ask_about_panic_saveFunction · 0.85
libnhmain.cFile · 0.85
mainFunction · 0.85
pcmainFunction · 0.85
goto_levelFunction · 0.85
clearlocksFunction · 0.85
recover_savefileFunction · 0.85
dosave0Function · 0.85
MAINFunction · 0.85
mainFunction · 0.85

Calls 3

unlinkFunction · 0.85
fqnameFunction · 0.85
set_levelfile_nameFunction · 0.70

Tested by

no test coverage detected