mirror of
https://github.com/patchzyy/wiicompiled
synced 2026-09-10 17:16:47 -04:00
Report NAND move destination conflicts correctly
This commit is contained in:
@@ -384,6 +384,10 @@ extern "C" int32_t NANDMove_HLE(uint32_t srcPathPtr, uint32_t dstPathPtr) {
|
||||
return NAND_RESULT_OK;
|
||||
}
|
||||
|
||||
if (ec == std::errc::file_exists) {
|
||||
return NAND_RESULT_EXISTS;
|
||||
}
|
||||
|
||||
LogNandError("NANDMove", "FAILED error=%d message='%s'", ec.value(), ec.message().c_str());
|
||||
return NAND_RESULT_UNKNOWN;
|
||||
}
|
||||
|
||||
@@ -6,5 +6,7 @@
|
||||
// Move without replacing an existing entry. Cross-filesystem regular files are
|
||||
// staged at the destination before removing the source. On failure the source
|
||||
// remains; a failed source removal can leave both complete copies.
|
||||
// The caller must keep the source stable for the duration of the move; NAND HLE
|
||||
// calls run synchronously on the cooperative guest thread without yielding.
|
||||
void NandMove(const std::filesystem::path& source, const std::filesystem::path& destination,
|
||||
std::error_code& ec);
|
||||
|
||||
Reference in New Issue
Block a user