-
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
Restrict CCompRC::LoadResourceFile and usage to win #41757
Conversation
I couldn't figure out the best area label to add to this PR. If you have write-permissions please help me learn by adding exactly one area label. |
It is not interesting to do anything here unless it is part of a larger plan for localization of error messages produced by unmanaged code. You can replace the UNIXTODO with a comment or something. cc @janvorli |
src/coreclr/src/utilcode/ccomprc.cpp
Outdated
@@ -605,6 +609,8 @@ HRESULT CCompRC::LoadLibraryHelper(HRESOURCEDLL *pHInst, | |||
return hr; | |||
EX_TRY | |||
{ | |||
// String resouces packaged as PE files only exist on Windows | |||
#ifdef HOST_WINDOWS |
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.
You can use just single #ifdef / #endif with th3 #ifdef before the EX_TRY above and #endif before the return.
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.
The whole function should be unreachable on non-Windows. It would be best to itdef-out the whole function.
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.
Moved LoadLibraryHelper and LoadResourceFile functions under a single ifdef.
String resouces packaged as PE files only exist on Windows.
Test failure is #37132 |
Thanks! |
String resouces packaged as PE files only exist on Windows.