MCPcopy Create free account
hub / github.com/MarlinFirmware/Marlin / removeJobRecoveryFile

Method removeJobRecoveryFile

Marlin/src/sd/cardreader.cpp:1581–1590  ·  view source on GitHub ↗

Removing the job recovery file currently requires closing the file being printed, so during SD printing the file should be zeroed and written instead of deleted.

Source from the content-addressed store, hash-verified

1579 // the file being printed, so during SD printing the file should
1580 // be zeroed and written instead of deleted.
1581 void CardReader::removeJobRecoveryFile() {
1582 if (jobRecoverFileExists()) {
1583 recovery.init();
1584 removeFile(recovery.filename);
1585 TERN_(SOVOL_SV06_RTS, poweroff_continue = false);
1586 #if ENABLED(DEBUG_POWER_LOSS_RECOVERY)
1587 SERIAL_ECHOLN(F("Power-loss file delete"), jobRecoverFileExists() ? F(" failed.") : F("d."));
1588 #endif
1589 }
1590 }
1591
1592#endif // POWER_LOSS_RECOVERY
1593

Callers 3

sdCardStopMethod · 0.80
handleDataMethod · 0.80
purgeMethod · 0.80

Calls 3

SERIAL_ECHOLNFunction · 0.50
FFunction · 0.50
initMethod · 0.45

Tested by

no test coverage detected