GNOME Bugzilla – Bug 333551
eog assert failure when loading file with strange extension
Last modified: 2006-03-06 01:40:57 UTC
1. Run eog somefile.bin where somefile.bin is a jpeg with the extension ".bin" 2. Eog decides to display the contents of the entire directory in which the file is located. 3. Eog scans the directory for known images. 4. .bin is not added to the list of known images. 5. Eog tries to set the "current" image to somefile.bin and fails because it is not in the list. 6. Eog tries to open image -1 which returns NULL and triggers an assert failure. Attached is a patch to explicitly allow the loading of images specified on the commandline even if they are not 'found' in the directory.
Created attachment 60726 [details] [review] fix. Note: I remove a check that a file has a valid mime type in the add_regular code. This means that eog will allow you to load files with strange extensions. This triggers another bug in eog: If you load a file that eog is unable to handle then it will not show the UI. This bug, however, exists even now (without my patch) if you try to open somefile.jpeg that is really a PDF or something. eog will start and run but never display its main window.
Bug 333552 opened for the issue mentioned above. Elevating priority of this bug due to the patch.