소스 검색

Fix SD card hotswap bug when the SCSI host is constantly polling

Michael McMaster 6 년 전
부모
커밋
fb8c24f523
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      lib/SCSI2SD/src/firmware/main.c

+ 1 - 1
lib/SCSI2SD/src/firmware/main.c

@@ -161,7 +161,7 @@ void mainLoop()
 #endif
 		}
 	}
-	else if (scsiDev.phase >= 0)
+	else if ((scsiDev.phase >= 0) && (blockDev.state & DISK_PRESENT))
 	{
 		// don't waste time scanning SD cards while we're doing disk IO
 		lastSDPoll = s2s_getTime_ms();