10000 Replace 'api-ms-win-core-job-12-1-0.dll' with 'Kernell32.dll' by iSazonov · Pull Request #10417 · PowerShell/PowerShell · GitHub
[go: up one dir, main page]

Skip to content

Conversation

@iSazonov
Copy link
Collaborator
@iSazonov iSazonov commented Aug 22, 2019

PR Summary

Fix #6561

PR Context

PR Checklist

@iSazonov iSazonov added the CL-General Indicates that a PR should be marked as a general cmdlet change in the Change Log label Aug 22, 2019
@iSazonov iSazonov added this to the 7.0.0-preview.4 milestone Aug 22, 2019
@adityapatwardhan
Copy link
Member

@iSazonov The same DLL is used by AssignProcessToJobObjectDllName and QueryInformationJobObjectDllName. Do these also not work on Win7?

If we are replacing them with kernel32.dll, have you verified the change on win7throughwin10`?

If replacing with kernel32.dll works, should we be removing the definitions from PInvokeDllNames.cs.

@iSazonov
Copy link
Collaborator Author

@adityapatwardhan I removed all links to api-ms-win-core-job-l2-1-0.dll and now it works for me on Windows 7.

should we be removing the definitions from PInvokeDllNames.cs

There is already some unused consts, the list is large and numerated, also we could want to use ApiSets again after Windows 7 EOL. I think we need to keep the consts.

@daxian-dbw
Copy link
Member

Do we know if things are still working properly on NanoServer and Windows IoT after changing to kernal32.dll?

@iSazonov
< 8000 /svg> Copy link
Collaborator Author
iSazonov commented Aug 30, 2019

I can not test on Nano and IoT.
I saw that .Net Core team replaced ApiSets with direct dll names because of many such problems with ApiSets.
See:
dotnet/corefx@75e45da
More: https://github.com/dotnet/corefx/search?q=ApiSets&type=Commits

Also I found https://www.geoffchappell.com/studies/windows/win32/apisetschema/history/sets61.htm where we can see that there is sometimes automapping (for Windows 7).

@adityapatwardhan
Copy link
Member

I have verified that the change works on NanoServer 1903 image.

@adityapatwardhan adityapatwardhan merged commit bbd54c3 into PowerShell:master Sep 3, 2019
@iSazonov iSazonov deleted the fix-unable-load-dll-api-ms-win-core branch September 4, 2019 03:12
TravisEz13 pushed a commit to TravisEz13/PowerShell that referenced this pull request Sep 14, 2019
@ghost
Copy link
ghost commented Sep 19, 2019

🎉v7.0.0-preview.4 has been released which incorporates this pull request.:tada:

Handy links:

@ForNeVeR
Copy link
Contributor

Hey, shouldn't we remove the corresponding constants from the PinvokeDllNames class since they are unused now?

@iSazonov
Copy link
Collaborator Author

@ForNeVeR We did not remove the constants because we will revert the change after Windows 7 EOL.

@ForNeVeR
Copy link
Contributor

Okay, thanks.

@adityapatwardhan adityapatwardhan added this to the 6.2.4 milestone Jan 18, 2020
@ghost
Copy link
ghost commented Jan 27, 2020

🎉v6.2.4 has been released which incorporates this pull request.:tada:

Handy links:

TravisEz13 pushed a commit to TravisEz13/PowerShell that referenced this pull request Feb 25, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CL-General Indicates that a PR should be marked as a general cmdlet change in the Change Log

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Start-Process: Unable to load DLL 'api-ms-win-core-job-12-1-0.dll'

5 participants

0