Skip to content

Commit dff07d0

Browse files
authored
Fix FileMove from delete file if FileCopy did not work (#5806)
1 parent 0f98d78 commit dff07d0

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/rcore.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2283,7 +2283,7 @@ int FileMove(const char *srcPath, const char *dstPath)
22832283

22842284
if (FileExists(srcPath))
22852285
{
2286-
if (FileCopy(srcPath, dstPath) == 0) result = FileRemove(srcPath);
2286+
if (FileCopy(srcPath, dstPath)) result = FileRemove(srcPath);
22872287
else TRACELOG(LOG_WARNING, "FILEIO: [%s] Failed to copy file to [%s]", srcPath, dstPath);
22882288
}
22892289
else TRACELOG(LOG_WARNING, "FILEIO: [%s] Source file does not exist", srcPath);

0 commit comments

Comments
 (0)