Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8213366

(fs) avoid handle leak in Java_sun_nio_fs_WindowsNativeDispatcher_FindFirstFile0

    XMLWordPrintable

    Details

    • Subcomponent:
    • Resolved In Build:
      b19
    • OS:
      windows
    • Verification:
      Not verified

      Description

      In Java_sun_nio_fs_WindowsNativeDispatcher_FindFirstFile0, we have a special case where a handle obtained by FindFirstFileW has to be closed but is currently not closed. This could leak in seldom cases to leaks.
      FindFirstFileW returns a handle in case of a successful call . However this handle has to be closed later (with FindClose, see MSDN docu). In the special case of failing (*env)->NewString(...) , we miss the closing.

        Attachments

          Activity

            People

            • Assignee:
              mbaesken Matthias Baesken
              Reporter:
              mbaesken Matthias Baesken
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: