jim-easterbrook / Photini

An easy to use digital photograph metadata (Exif, IPTC, XMP) editing application.
https://photini.readthedocs.io/
GNU General Public License v3.0
157 stars 24 forks source link

Sporadic segfault on shutdown #18

Closed jim-easterbrook closed 8 years ago

jim-easterbrook commented 8 years ago

Very occasionally I get a 'segfault' message when quitting Photini. I'm unable to make this happen repeatedly and am having difficulty tracking it down. It seems harmless, but I wish it didn't do it.

I tried rearranging the 'main' function as described in http://pyqt.sourceforge.net/Docs/PyQt5/pyqt4_differences.html#object-destruction-on-exit but it didn't stop the problem, and also stopped setup.py creating an 'entry point' for the program.

[Since writing this the PyQt5 document has been edited, removing stuff about rearranging the 'main' function.]

jim-easterbrook commented 8 years ago

I've managed to find a repeatable segfault: start photini, switch to the OSM map tab, load the map, then quit. It doesn't segfault if using either of the other maps or if using Python 2. (This is on OpenSuse Linux, running on Windows is problem free.)

jim-easterbrook commented 8 years ago

Commit 5d7b255 seems to have cured the OSM map segfaults.

jim-easterbrook commented 8 years ago

I've found another reliable way to create a segfault: select one of the uploader tabs, click on connect and then quit (ctrl-q) while it's busy. As soon as it finishes connecting it quits with a segfault when using PyQt5 but is fine with PyQt4.

jim-easterbrook commented 8 years ago

Further reading and experimenting suggests it's a problem with the KDE "oxygen" theme (and its derivatives). Running Photini with the gtk or windows theme prevents the segfault:

python3 -m photini.editor -style gtk
jim-easterbrook commented 8 years ago

Commit f9a6d52 seems to have (at last) put an end to these sporadic segmentation faults.