Skip to content

Conversation

@adityapatwardhan
Copy link
Member

@adityapatwardhan adityapatwardhan commented Apr 25, 2023

PR Summary

Ensure the native PInvoke call has SetLastError in the LibraryImport attribuute. We use the last error to determine the correct fully qualified error id.

PR Context

PR Checklist

@iSazonov
Copy link
Collaborator

Could you please point a code where we use the last error? I don't see using GetLastWin32Error/GetLastError.

@SeeminglyScience
Copy link
Collaborator

Could you please point a code where we use the last error? I don't see using GetLastWin32Error/GetLastError.

Yeah it's called here

@daxian-dbw daxian-dbw merged commit 72c81b8 into PowerShell:master May 1, 2023
@daxian-dbw daxian-dbw added the CL-General Indicates that a PR should be marked as a general cmdlet change in the Change Log label May 1, 2023
@ghost
Copy link

ghost commented Jun 29, 2023

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

Handy links:

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.

7 participants