Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

SetLastError as true for Symbolic and Hard Link native APIs#19566

Merged
daxian-dbw merged 1 commit into
PowerShell:masterPowerShell/PowerShell:masterfrom
adityapatwardhan:FixSetLastErroradityapatwardhan/PowerShell:FixSetLastErrorCopy head branch name to clipboard
May 1, 2023
Merged

SetLastError as true for Symbolic and Hard Link native APIs#19566
daxian-dbw merged 1 commit into
PowerShell:masterPowerShell/PowerShell:masterfrom
adityapatwardhan:FixSetLastErroradityapatwardhan/PowerShell:FixSetLastErrorCopy head branch name to clipboard

Conversation

@adityapatwardhan

@adityapatwardhan adityapatwardhan commented Apr 25, 2023

Copy link
Copy Markdown
Member

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
Copy Markdown
Collaborator

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

@SeeminglyScience

Copy link
Copy Markdown
Contributor

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

ghost commented Jun 29, 2023

Copy link
Copy Markdown

🎉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

Morty Proxy This is a proxified and sanitized view of the page, visit original site.