MCPcopy Create free account
hub / github.com/clementgallet/libTAS / removeFromDisk

Method removeFromDisk

src/library/fileio/SaveFile.cpp:532–548  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

530}
531
532bool SaveFile::removeFromDisk() const {
533 if (fd == 0)
534 return true;
535
536 if (fd >= FIRST_SAVEFILE_STREAM_FD)
537 return true;
538
539 LOG(LL_DEBUG, LCF_FILEIO, "Remove file %s from disk", filename.c_str());
540 GlobalNative gn;
541 int ret = ::remove(filename.c_str());
542 if (ret < 0) {
543 LOG(LL_WARN, LCF_FILEIO, "Could not remove file %s", filename.c_str());
544 return false;
545 }
546
547 return true;
548}
549
550}

Callers 1

dlopenFunction · 0.80

Calls 2

removeFunction · 0.85
c_strMethod · 0.45

Tested by

no test coverage detected