Added a workaround for Alcohol/DT virtual drive bug#16
Open
NicknineTheEagle wants to merge 2 commits intoRibShark:mainfrom
Open
Added a workaround for Alcohol/DT virtual drive bug#16NicknineTheEagle wants to merge 2 commits intoRibShark:mainfrom
NicknineTheEagle wants to merge 2 commits intoRibShark:mainfrom
Conversation
45f0b06 to
6ebd70e
Compare
02b9411 to
5026b11
Compare
|
Maybe a nice addition could be to log the name of the disc drive too? |
Properly disable logs on Release build, fixed early logs not being flushed to the file
5026b11 to
f1632e0
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This introduces a workaround for a bug in SATA controller used by Alcohol and DAEMON Tools where it doesn't return LOGICAL_BLOCK_ADDRESS_OUT_OF_RANGE error for out-of-range sector reads - this includes track 1 pregap which later versions of SafeDisc try to check. If the disc drive returns an error then SafeDisc gives up and doesn't bother checking pregap but the controller returns success code despite not actually returning any sector data so SafeDisc keeps checking pregap and then fails the disc check since it did not receive valid data from the virtual drive.
This is only present on SATA controller which Alcohol (and presumably DT) uses on Windows 10. On Windows 7 and below, Alcohol emulates SCSI drive which doesn't have this bug.
The workaround checks if read command on negative LBA was attempted and success code was returned with empty output buffer. If yes, it manually writes LOGICAL_BLOCK_ADDRESS_OUT_OF_RANGE error.