#10 Open dialog bug not fixed

v2.6.4
closed-fixed
None
5
2014-04-19
2012-12-18
No

Hi - I downloaded 2.6.2, but I'm still getting the same file open dialog backtrace as before in #3596850.

This is what the preferences file looks like after loading a file:
#Tue Dec 18 09:12:12 CET 2012
lastPath=/data11s/jsanders/progtars/PlotDigitizer_Linux_and_Others/SamplePlots/figure64.gif

Also, if the preferences file .jahuwaldt.Digitizer.pro is deleted, the program gives this exception on startup, but starts ok.

ds22:~/data1/progtars/PlotDigitizer_Linux_and_Others:$ java -jar PlotDigitizer.jar java.io.IOException: Stream Closed
at java.io.FileInputStream.readBytes(Native Method)
at java.io.FileInputStream.read(FileInputStream.java:236)
at sun.nio.cs.StreamDecoder.readBytes(StreamDecoder.java:282)
at sun.nio.cs.StreamDecoder.implRead(StreamDecoder.java:324)
at sun.nio.cs.StreamDecoder.read(StreamDecoder.java:176)
at java.io.InputStreamReader.read(InputStreamReader.java:184)
at java.io.BufferedReader.fill(BufferedReader.java:153)
at java.io.BufferedReader.readLine(BufferedReader.java:316)
at java.io.BufferedReader.readLine(BufferedReader.java:379)
at jahuwaldt.io.StreamGobbler.run(StreamGobbler.java:57)
Dec 18, 2012 9:09:53 AM AppWindow <init>
INFO: Application starting...

Discussion

  • Joseph A. Huwaldt

    • assigned_to: nobody --> jhuwaldt
     
  • Joseph A. Huwaldt

    Thanks.

    Sorry I closed the other bug report prematurely then. I was SO confident that I had fixed it.

    Could you please post the error report you are getting now. It should at least show some new line numbers where the exception is being thrown.

    I do not have access to a Linux box right now, so I can't test this directly and it does not happen on MacOS (that I have been able to replicate anyway). I may have to send you some test code to try and work out what is going on.

     
  • Jeremy Sanders

    Jeremy Sanders - 2012-12-18

    It looks the same, though the line numbers might be different

    java.lang.reflect.InvocationTargetException
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:616)
    at jahuwaldt.swing.GenericActionListener.actionPerformed(GenericActionListener.java:47)
    at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:2012)
    at javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2335)
    at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:404)
    at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:259)
    at javax.swing.AbstractButton.doClick(AbstractButton.java:374)
    at javax.swing.plaf.basic.BasicMenuItemUI.doClick(BasicMenuItemUI.java:829)
    at javax.swing.plaf.basic.BasicMenuItemUI$Handler.mouseReleased(BasicMenuItemUI.java:873)
    at java.awt.Component.processMouseEvent(Component.java:6389)
    at javax.swing.JComponent.processMouseEvent(JComponent.java:3268)
    at java.awt.Component.processEvent(Component.java:6154)
    at java.awt.Container.processEvent(Container.java:2045)
    at java.awt.Component.dispatchEventImpl(Component.java:4750)
    at java.awt.Container.dispatchEventImpl(Container.java:2103)
    at java.awt.Component.dispatchEvent(Component.java:4576)
    at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4633)
    at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4297)
    at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4227)
    at java.awt.Container.dispatchEventImpl(Container.java:2089)
    at java.awt.Window.dispatchEventImpl(Window.java:2518)
    at java.awt.Component.dispatchEvent(Component.java:4576)
    at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:672)
    at java.awt.EventQueue.access$400(EventQueue.java:96)
    at java.awt.EventQueue$2.run(EventQueue.java:631)
    at java.awt.EventQueue$2.run(EventQueue.java:629)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:105)
    at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:116)
    at java.awt.EventQueue$3.run(EventQueue.java:645)
    at java.awt.EventQueue$3.run(EventQueue.java:643)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:105)
    at java.awt.EventQueue.dispatchEvent(EventQueue.java:642)
    at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:275)
    at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:200)
    at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:190)
    at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:185)
    at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:177)
    at java.awt.EventDispatchThread.run(EventDispatchThread.java:138)
    Caused by: java.lang.NullPointerException
    at sun.awt.X11.XFileDialogPeer.setDirectory(XFileDialogPeer.java:716)
    at java.awt.FileDialog.setDirectory(FileDialog.java:357)
    at jahuwaldt.swing.AppUtilities.selectFile(AppUtilities.java:969)
    at AppWindow.handleOpen(AppWindow.java:1025)
    ... 43 more

     
  • Joseph A. Huwaldt

    This problem seems to only be happening on Ubuntu. I have gotten no reports on this from other platforms.

    I think that the problem is occurring in the Java libraries themselves and not in my code. However, there is a work around for the moment until I get a better fix in place. Try deleting the preference file from the root of your account. It should have a name like: ".jahuwaldt.plotdigitizer.prefs" or something (I can't quite remember right now). Or, you can edit that file and delete the "previousPath" item from it. You will have to delete this preference file every time you run the program (maybe do that in a batch script).

    This is happening when I tell the Java File Dialog to return you to the path of the last file you opened. My code checks to make sure that the previous path exists and you can read from it before passing it to the Java FileDialog, but you still get an exception on Ubuntu. I may have to add some code to check for Ubuntu an disable this feature on that platform.

     
  • Jeremy Sanders

    Jeremy Sanders - 2013-02-26

    Sorry. Which version did you want me to look at? I've tried 2.6.3B1 which you sent me. Which gives the exception below:

    ds22:~:$ java -jar PlotDigitizer_2.6.3B1.jar
    Dec 18, 2012 1:41:21 PM AppWindow <init>
    INFO: Application starting...
    directory = /data11s/jsanders/progtars/PlotDigitizer_Linux_and_Others/SamplePlots/figure64.gif
    is directory check 1: false
    is directory check 2: true
    exists: true
    java.lang.reflect.InvocationTargetException
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:616)
    at jahuwaldt.swing.GenericActionListener.actionPerformed(GenericActionListener.java:47)
    at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:2012)
    at javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2335)
    at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:404)
    at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:259)
    at javax.swing.AbstractButton.doClick(AbstractButton.java:374)
    at javax.swing.plaf.basic.BasicMenuItemUI.doClick(BasicMenuItemUI.java:829)
    at javax.swing.plaf.basic.BasicMenuItemUI$Handler.mouseReleased(BasicMenuItemUI.java:873)
    at java.awt.Component.processMouseEvent(Component.java:6389)
    at javax.swing.JComponent.processMouseEvent(JComponent.java:3268)
    at java.awt.Component.processEvent(Component.java:6154)
    at java.awt.Container.processEvent(Container.java:2045)
    at java.awt.Component.dispatchEventImpl(Component.java:4750)
    at java.awt.Container.dispatchEventImpl(Container.java:2103)
    at java.awt.Component.dispatchEvent(Component.java:4576)
    at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4633)
    at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4297)
    at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4227)
    at java.awt.Container.dispatchEventImpl(Container.java:2089)
    at java.awt.Window.dispatchEventImpl(Window.java:2518)
    at java.awt.Component.dispatchEvent(Component.java:4576)
    at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:672)
    at java.awt.EventQueue.access$400(EventQueue.java:96)
    at java.awt.EventQueue$2.run(EventQueue.java:631)
    at java.awt.EventQueue$2.run(EventQueue.java:629)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:105)
    at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:116)
    at java.awt.EventQueue$3.run(EventQueue.java:645)
    at java.awt.EventQueue$3.run(EventQueue.java:643)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:105)
    at java.awt.EventQueue.dispatchEvent(EventQueue.java:642)
    at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:275)
    at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:200)
    at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:190)
    at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:185)
    at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:177)
    at java.awt.EventDispatchThread.run(EventDispatchThread.java:138)
    Caused by: java.lang.NullPointerException
    at sun.awt.X11.XFileDialogPeer.setDirectory(XFileDialogPeer.java:716)
    at java.awt.FileDialog.setDirectory(FileDialog.java:357)
    at jahuwaldt.swing.AppUtilities.selectFile(AppUtilities.java:975)
    at AppWindow.handleOpen(AppWindow.java:1025)
    ... 43 more

     
  • Joseph A. Huwaldt

    I believe I have finally found a work-around for this illusive bug. Please try version 2.6.4 (just uploaded) and let me know if it solves the problem. Thank you.

    Joe Huwaldt

     
  • Joseph A. Huwaldt

    • status: open --> closed-fixed
    • Group: --> v2.2.0
     
  • Joseph A. Huwaldt

    I believe this was fixed in 2.6.4 as I no longer receive bug reports on it.

     
  • Joseph A. Huwaldt

    • Group: v2.2.0 --> v2.6.4
     

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks