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

Correct typemapper used for structures defined #686

Merged

Conversation

matthiasblaesing
Copy link
Member

Winnetwk definitions follow the typemapper set by the "w32.ascii"
property, following the convention demonstrated/used in
W32APIOptions.DEFAULT.

The definitions in LMShare are defined as pure UNICODE.

Closes: #668

@matthiasblaesing
Copy link
Member Author

This is incomplete, as the other files modified by #541 need to be checked. Please don't merge I'll revisit this.

}

public SHARE_INFO_2(Pointer memory) {
super(memory);
super(memory, Structure.ALIGN_DEFAULT, W32APITypeMapper.UNICODE);
Copy link
Contributor

Choose a reason for hiding this comment

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

Is this structure only valid in its unicode form?

Copy link
Member Author

@matthiasblaesing matthiasblaesing Jul 27, 2016

Choose a reason for hiding this comment

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

@matthiasblaesing
Copy link
Member Author

Ok - with the updates of the typemappings and the updated tests I'm down to a few flaky tests. On x86 I'm seeing a consistent failure in the tests, that utilize MonitorFromPoint which return NULL on x86. The definition looks sane so I'll ignore it for now.

@@ -39,6 +39,12 @@ public static void main(String[] args) throws Exception {
junit.textui.TestRunner.run(MprTest.class);
}

public void testCreateLocalShare() throws Exception {
Copy link
Contributor

Choose a reason for hiding this comment

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

createLocalShare was just a private helper function for the other tests, so I wouldn't say it needs its own test. But of course, it can't hurt.

@matthiasblaesing matthiasblaesing force-pushed the winnetwk_mapping branch 2 times, most recently from fe19eca to 2e031ba Compare August 2, 2016 17:32
Winnetwk definitions follow the typemapper set by the "w32.ascii"
property, following the convention demonstrated/used in
W32APIOptions.DEFAULT.

The definitions in LMShare are defined as pure UNICODE.

Closes: java-native-access#668
- Registry Keys are documented as case insensitive
  https://msdn.microsoft.com/de-de/library/windows/desktop/ms724946(v=vs.85).aspx
- Improve stability of COM Tests by killing IE to ensure clean state
- Prevent failures because of wrong locale (skip error message
  generation tests or use locale independent API)
- OpenProcess with correct permissions
- Free correct value in Secur32Test
- Tolerate more complex scenarios in VolumeManagementFunctions
  (hidden partions)
- Handle DxvaTest when monitor does not supply capablilities string
- Use correct comparison operator for version check
- Tolerate invalid environment strings
- MonitorFromPoint is known to fail on 32bit => use MonitorFromWindow
@matthiasblaesing matthiasblaesing merged commit 5d7e4b0 into java-native-access:master Aug 2, 2016
@matthiasblaesing matthiasblaesing deleted the winnetwk_mapping branch August 5, 2016 22:45
mstyura pushed a commit to mstyura/jna that referenced this pull request Sep 9, 2024
…ess#686)

Motivation:

QuicheQuicCodec keeps state and so can not be sharable, let's enforce
this.

Modifications:

- Override isSharable() and return false

Result:

Ensure sub-types can not be sharable
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