Eject SCSI DirectAccess devices if removable in device-report.

This commit is contained in:
2019-11-01 01:10:48 +00:00
parent 67a524e5ba
commit 18507d0ef0

View File

@@ -605,8 +605,6 @@ namespace DiscImageChef.Commands
if (pressedKey.Key != ConsoleKey.Y) continue; if (pressedKey.Key != ConsoleKey.Y) continue;
dev.AllowMediumRemoval(out senseBuffer, dev.Timeout, out _);
dev.EjectTray(out senseBuffer, dev.Timeout, out _);
DicConsole DicConsole
.WriteLine("Please insert it in the drive and press any key when it is ready."); .WriteLine("Please insert it in the drive and press any key when it is ready.");
System.Console.ReadKey(true); System.Console.ReadKey(true);
@@ -999,6 +997,9 @@ namespace DiscImageChef.Commands
mediaTest.MediaIsRecognized = mediaIsRecognized; mediaTest.MediaIsRecognized = mediaIsRecognized;
mediaTests.Add(mediaTest); mediaTests.Add(mediaTest);
dev.AllowMediumRemoval(out buffer, dev.Timeout, out _);
dev.EjectTray(out buffer, dev.Timeout, out _);
} }
report.SCSI.RemovableMedias = mediaTests; report.SCSI.RemovableMedias = mediaTests;