-
Notifications
You must be signed in to change notification settings - Fork 4.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[mono] Fix second pass of MarshallingPInvokeScanner with metadata-free DLLs #89555
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
@@ -81,6 +81,9 @@ private void ResolveInconclusiveTypes(HashSet<string> incompatible, string assyP | |||
|
|||
using FileStream file = new FileStream(assyPath, FileMode.Open, FileAccess.Read, FileShare.ReadWrite); | |||
using PEReader peReader = new PEReader(file); | |||
if (!peReader.HasMetadata) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit: May be good to encapsulate this, so we don't forget to check peReader.HasMetadata each time it is created, but I think it is nice to have.
/azp run runtime-ioslike |
No commit pushedDate could be found for PR 89555 in repo dotnet/runtime |
/azp run runtime-ioslike |
No commit pushedDate could be found for PR 89555 in repo dotnet/runtime |
/azp run runtime-ioslike |
Azure Pipelines successfully started running 1 pipeline(s). |
The failure looks related. The scanner invokes GetAssemblyName which ends up with: Lines 85 to 87 in 95cbec1
|
/azp run runtime-ioslike |
Azure Pipelines successfully started running 1 pipeline(s). |
The failures shouldn't be related. Thanks! |
This fixes the second pass of #89429 when trying to read DLLs that have no metadata. The first pass was addressed in #89430.