-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
Added standard Kernel32Util#closeHandle method that throws an exception if failed to close the handle #614
Conversation
eac4644
to
946a453
Compare
@@ -42,6 +42,7 @@ Features | |||
* [#612](https://github.com/java-native-access/jna/pull/612): Kernel32Util#freeLocal/GlobalMemory always throws Win32Exception if failed [@lgoldstein](https://github.com/lgoldstein). | |||
* [#608](https://github.com/java-native-access/jna/pull/608): Mavenize the build process - change parent and native pom artifactId/name to differentiate in IDE and build tools. [@bhamail](https://github.com/bhamail) | |||
* [#613](https://github.com/java-native-access/jna/pull/613): Make Win32Exception extend LastErrorException [@lgoldstein](https://github.com/lgoldstein). | |||
* [#613](https://github.com/java-native-access/jna/pull/614): Added standard Kernel32Util#closeHandle method that throws a eption if failed to close the handle [@lgoldstein](https://github.com/lgoldstein). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
throws a .... exception :) Also quote these function names in backticks probably (and above).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Will do.
Correct the typo in CHANGELOG, otherwise feel free to merge, code looks good. |
…eption if failed to close the handle
Added standard Kernel32Util#closeHandle method that throws an exception if failed to close the handle
@@ -39,9 +39,10 @@ Features | |||
* [#595](https://github.com/java-native-access/jna/pull/595): Allow calling COM methods/getters requiring hybrid calling (METHOD+PROPERTYGET) - [@matthiasblaesing](https://github.com/matthiasblaesing). | |||
* [#582](https://github.com/java-native-access/jna/pull/582): Mavenize the build process - Phase 1: building the native code via Maven [@lgoldstein](https://github.com/lgoldstein). | |||
* [#606](https://github.com/java-native-access/jna/pull/606): Added Kerne32Util method to facilitate checking that calls to LocalFree/GlobalFree are successful [@lgoldstein](https://github.com/lgoldstein). | |||
* [#612](https://github.com/java-native-access/jna/pull/612): Kernel32Util#freeLocal/GlobalMemory always throws Win32Exception if failed [@lgoldstein](https://github.com/lgoldstein). | |||
* [#612](https://github.com/java-native-access/jna/pull/612): 'Kernel32Util#freeLocal/GlobalMemory' always throws Win32Exception if failed [@lgoldstein](https://github.com/lgoldstein). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Those backticks are the wrong kind ;) Also above there's a typo, Kerne32Util is missing an L :)
Provide bolierplate template for code that is supposed to close a handle and check the returned error code if failed to do so