The desktop configuration file is corrupt or improperly formatted when starting matlab
78 views (last 30 days)
Show older comments
After not using Matlab for a while, I got the following error in the command window after starting matlab. Thank you in advance
Warning/Error message:
Warning: The desktop configuration file is corrupt or improperly formatted.
null
Warning: An error occurred while reading the desktop configuration file.
Using the default configuration.
Warning: The desktop configuration file is corrupt or improperly formatted.
null
Warning: An error occurred while reading the desktop configuration file.
Exception in thread "AWT-EventQueue-0": java.lang.NullPointerException
at com.mathworks.mde.liveeditor.LiveEditorTabManager.showEditorInBrowser(LiveEditorTabManager.java:932)
at com.mathworks.mde.liveeditor.LiveEditorTabManager.handleClientDisplayed(LiveEditorTabManager.java:310)
at com.mathworks.mde.liveeditor.LiveEditorTabManager$2.run(LiveEditorTabManager.java:293)
at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:311)
at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:758)
at java.awt.EventQueue.access$500(EventQueue.java:97)
at java.awt.EventQueue$3.run(EventQueue.java:709)
at java.awt.EventQueue$3.run(EventQueue.java:703)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:74)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:728)
at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:205)
at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:116)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:105)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:93)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:82)
Exception in thread "AWT-EventQueue-0": java.lang.NullPointerException
at com.mathworks.mde.liveeditor.LiveEditorTabManager.showEditorInBrowser(LiveEditorTabManager.java:932)
at com.mathworks.mde.liveeditor.LiveEditorTabManager.handleClientDisplayed(LiveEditorTabManager.java:310)
at com.mathworks.mde.liveeditor.LiveEditorTabManager.handleClientHierarchyChanged(LiveEditorTabManager.java:276)
at com.mathworks.mde.liveeditor.LiveEditorClient$46.hierarchyChanged(LiveEditorClient.java:1885)
at java.awt.AWTEventMulticaster.hierarchyChanged(AWTEventMulticaster.java:499)
at java.awt.Component.processHierarchyEvent(Component.java:6706)
at java.awt.Component.processEvent(Component.java:6325)
at java.awt.Container.processEvent(Container.java:2239)
at java.awt.Component.dispatchEventImpl(Component.java:4889)
at java.awt.Container.dispatchEventImpl(Container.java:2297)
at java.awt.Component.dispatchEvent(Component.java:4711)
at java.awt.Component.createHierarchyEvents(Component.java:5555)
at java.awt.Container.createHierarchyEvents(Container.java:1448)
at java.awt.Container.createHierarchyEvents(Container.java:1444)
at java.awt.Container.createHierarchyEvents(Container.java:1444)
at java.awt.Component.show(Component.java:1639)
at java.awt.Component.show(Component.java:1671)
at java.awt.Component.setVisible(Component.java:1623)
at javax.swing.JComponent.setVisible(JComponent.java:2644)
at com.mathworks.widgets.desk.DTTabbedDocumentPane.show(DTTabbedDocumentPane.java:371)
at com.mathworks.widgets.desk.DTTabbedDocumentPane.toFront(DTTabbedDocumentPane.java:251)
at com.mathworks.widgets.desk.DTDocumentContainer.toFront(DTDocumentContainer.java:532)
at com.mathworks.widgets.desk.DTDocumentContainer.propertyChange(DTDocumentContainer.java:1817)
at com.mathworks.widgets.desk.DTOccupant.forwardPropertyChange(DTOccupant.java:1197)
at com.mathworks.widgets.desk.DTClient.itemStateChanged(DTClient.java:1641)
at com.mathworks.widgets.desk.DTInternalFrame.setSelected(DTInternalFrame.java:364)
at com.mathworks.widgets.desk.DTClient.setSelected(DTClient.java:488)
at com.mathworks.widgets.desk.DTOccupant.setSelected(DTOccupant.java:822)
at com.mathworks.widgets.desk.DTDocumentContainer.setSelected(DTDocumentContainer.java:1071)
at com.mathworks.widgets.desk.DTDocumentContainer.setSelected(DTDocumentContainer.java:1037)
at com.mathworks.widgets.desk.DTGroup.setSelected(DTGroup.java:1077)
at com.mathworks.widgets.desk.DTSelectionManager.eventDispatched(DTSelectionManager.java:421)
at java.awt.Toolkit$SelectiveAWTEventListener.eventDispatched(Toolkit.java:2427)
at java.awt.Toolkit$ToolkitEventMulticaster.eventDispatched(Toolkit.java:2319)
at java.awt.Toolkit$ToolkitEventMulticaster.eventDispatched(Toolkit.java:2318)
at java.awt.Toolkit$ToolkitEventMulticaster.eventDispatched(Toolkit.java:2318)
at java.awt.Toolkit$ToolkitEventMulticaster.eventDispatched(Toolkit.java:2318)
at java.awt.Toolkit$ToolkitEventMulticaster.eventDispatched(Toolkit.java:2318)
at java.awt.Toolkit$ToolkitEventMulticaster.eventDispatched(Toolkit.java:2318)
at java.awt.Toolkit$ToolkitEventMulticaster.eventDispatched(Toolkit.java:2318)
at java.awt.Toolkit$ToolkitEventMulticaster.eventDispatched(Toolkit.java:2318)
at java.awt.Toolkit$ToolkitEventMulticaster.eventDispatched(Toolkit.java:2318)
at java.awt.Toolkit$ToolkitEventMulticaster.eventDispatched(Toolkit.java:2318)
at java.awt.Toolkit$ToolkitEventMulticaster.eventDispatched(Toolkit.java:2318)
at java.awt.Toolkit$ToolkitEventMulticaster.eventDispatched(Toolkit.java:2318)
at java.awt.Toolkit.notifyAWTEventListeners(Toolkit.java:2277)
at java.awt.Component.dispatchEventImpl(Component.java:4785)
at java.awt.Container.dispatchEventImpl(Container.java:2297)
at java.awt.Component.dispatchEvent(Component.java:4711)
at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4904)
at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4532)
at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4476)
at java.awt.Container.dispatchEventImpl(Container.java:2283)
at java.awt.Window.dispatchEventImpl(Window.java:2746)
at java.awt.Component.dispatchEvent(Component.java:4711)
at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:760)
at java.awt.EventQueue.access$500(EventQueue.java:97)
at java.awt.EventQueue$3.run(EventQueue.java:709)
at java.awt.EventQueue$3.run(EventQueue.java:703)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:74)
at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:84)
at java.awt.EventQueue$4.run(EventQueue.java:733)
at java.awt.EventQueue$4.run(EventQueue.java:731)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:74)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:730)
at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:205)
at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:116)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:105)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:93)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:82)
5 Comments
Walter Roberson
on 15 Aug 2022
If you were not using Linux, I would speculate that you might have a third-party function that is interfering with MATLAB operation, such as a function from SPM12's compatibility directories.
But since you are using Linux... well, the above is still possible, but it also becomes possible that you have an incompatible library file that needs to be moved out of the way... something like libC.so.6 . I am not qualified to chase down such problems, so you should ask Mathworks Support.
Walter Roberson
on 15 Aug 2022
Moved: Walter Roberson
on 18 Aug 2022
https://www.mathworks.com/matlabcentral/answers/329796-issue-with-libstdc-so-6#comment_2316900 is potentially relevant
Accepted Answer
zmi zmi
on 6 Sep 2022
The error may be fixed by setting aside the libfreetype.so.6 in <matlab_root>/bin/glnxa64/. Run the following command:
cd <matlab_root>/bin/glnxa64/
mv libfreetype.so.6 libfreetype.so.6.old
0 Comments
More Answers (1)
Keerthana Ramesh
on 18 Aug 2022
Moved: Walter Roberson
on 18 Aug 2022
Hi,
While launching MATLAB, if you receive the following error, there is a possibility that you might be using a different version of Java than the one shipped with MATLAB.
“ERROR: Warning: An error occurred while reading the desktop configuration file”
In order to check the version of Java that MATLAB is using, launch MATLAB and run the following command:
>> version -java
Check for a MATLAB_JAVA environment variable set on your system. If a MATLAB_JAVA environment variable is set, remove it and relaunch MATLAB twice to see if the issue persists.
If this does not help, it is also possible to resolve this via the following commands:
>> restoredefaultpath
>> rehash toolboxcache
>> savepath
I hope this information resolves the issue you are facing.
Thanks,
Keerthana
0 Comments
See Also
Categories
Find more on Startup and Shutdown in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!