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

Can not release file from MediaPlayer dispose() dosent work

XMLWordPrintable

    • x86_64
    • generic

      ADDITIONAL SYSTEM INFORMATION :
      standard win7 system

      A DESCRIPTION OF THE PROBLEM :
      The old workaround does not work on mp3 files. I have to completely shut the application down in order to delete or change a file.

      STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
      just load a few mp3 files sometimes the first one can be deleted but all others not.

      EXPECTED VERSUS ACTUAL BEHAVIOR :
      EXPECTED -
      windows says Java has still this file opened.

      ---------- BEGIN SOURCE ----------
      Media media = new Media("file path");
      MediaPlayer mp = new MediaPlayer(media);
      mp.play();
      mp.stop();
      mp.dispose();// does not work all time
      ---------- END SOURCE ----------

      CUSTOMER SUBMITTED WORKAROUND :
      Didn't find one.

      FREQUENCY : always


        1. MediaPlayer_Dispose_Issue_screenshot.png
          44 kB
          Priyanka Mangal
        2. MediaPlayerTest.java
          2 kB
          Priyanka Mangal

            pmangal Priyanka Mangal (Inactive)
            webbuggrp Webbug Group
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: