RFR: JDK-8292866: Java_sun_awt_shell_Win32ShellFolder2_getLinkLocation check MultiByteToWideChar return value for failures [v2]

Matthias Baesken mbaesken at openjdk.org
Fri Aug 26 07:54:24 UTC 2022


> https://docs.microsoft.com/en-us/windows/win32/api/stringapiset/nf-stringapiset-multibytetowidechar
> states about MultiByteToWideChar : "The function returns 0 if it does not succeed" and lists a few failure cases.
> However we miss checking the failure case in Java_sun_awt_shell_Win32ShellFolder2_getLinkLocation , seems we assume the function always works nicely (in most of the JDK coding the return value is checked ).

Matthias Baesken has updated the pull request incrementally with one additional commit since the last revision:

  Adjust added return syntax

-------------

Changes:
  - all: https://git.openjdk.org/jdk/pull/10015/files
  - new: https://git.openjdk.org/jdk/pull/10015/files/e4e71ef7..35960e95

Webrevs:
 - full: https://webrevs.openjdk.org/?repo=jdk&pr=10015&range=01
 - incr: https://webrevs.openjdk.org/?repo=jdk&pr=10015&range=00-01

  Stats: 6 lines in 1 file changed: 4 ins; 0 del; 2 mod
  Patch: https://git.openjdk.org/jdk/pull/10015.diff
  Fetch: git fetch https://git.openjdk.org/jdk pull/10015/head:pull/10015

PR: https://git.openjdk.org/jdk/pull/10015



More information about the client-libs-dev mailing list