Improved the fix.

This commit is contained in:
OBattler
2023-11-05 22:33:19 +01:00
parent 70a2ba0581
commit 33afe6e014

View File

@@ -2651,8 +2651,7 @@ ide_board_close(int board)
if (dev->type == IDE_ATAPI)
dev->tf->atastat = DRDY_STAT | DSC_STAT;
if ((dev->type == IDE_HDD) && (dev->tf != NULL)) {
else if (!(dev->type & IDE_SHADOW) && (dev->tf != NULL)) {
free(dev->tf);
dev->tf = NULL;
}