Skip to content
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

Fixed issue #604: Kernel32#GetLastError() always returns ERROR_SUCCESS #610

Merged
merged 1 commit into from
Mar 6, 2016

Conversation

lgoldstein
Copy link
Contributor

Corrected required overrides in the "short-circuit" code

@lgoldstein lgoldstein changed the title Fixed issue #604: Kernel#GetLastError() always returns ERROR_SUCCESS Fixed issue #604: Kernel32#GetLastError() always returns ERROR_SUCCESS Mar 5, 2016
@@ -109,7 +109,12 @@ private NativeLibrary(String libraryName, String libraryPath, long handle, Map<S
synchronized(functions) {
Function f = new Function(this, "GetLastError", Function.ALT_CONVENTION, encoding) {
@Override
Object invoke(Object[] args, Class<?> returnType, boolean b) {
Object invoke(Object[] args, Class<?> returnType, boolean b, int fixedArgs) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What's this one about?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I recently changed the lowest-level "invoke" signature when handling interface-based mappings in order to accommodate varargs correctly, as part of a varargs fix for arm. This is transparent to any existing usage, but I neglected to update the signature on this GetLastError short-circuit, with the result being that some (all?) calls directly to GetLastError would no longer be short-circuited.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Got it.

twall added a commit that referenced this pull request Mar 6, 2016
Fixed issue #604: Kernel32#GetLastError() always returns ERROR_SUCCESS
@twall twall merged commit 5521627 into java-native-access:master Mar 6, 2016
@lgoldstein lgoldstein deleted the issue-604 branch March 6, 2016 16:58
mstyura pushed a commit to mstyura/jna that referenced this pull request Sep 9, 2024
Motivation:

Quiche tagged a new release

Modifications:

Bump up sha to match latest quiche release

Result:

Use quiche 0.19.0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants