EOG crashes when opening a large file

Bug #1786268 reported by Theor
16
This bug affects 2 people
Affects Status Importance Assigned to Milestone
eog (Ubuntu)
Confirmed
Undecided
Unassigned

Bug Description

While opening a large file (eg, >8MB jpeg file), EOG segfaults with the following error:

------------------------------
(eog:16768): Gdk-ERROR **: 15:24:55.294: The program 'eog' received an X Window System error.
This probably reflects a bug in the program.
The error was 'BadAlloc (insufficient resources for operation)'.
  (Details: serial 1790 error_code 11 request_code 130 (MIT-SHM) minor_code 5)
  (Note to programmers: normally, X errors are reported asynchronously;
   that is, you will receive the error a while after causing it.
   To debug your program, run it with the GDK_SYNCHRONIZE environment
   variable to change this behavior. You can then get a meaningful
   backtrace from your debugger if you break on the gdk_x_error() function.)
Trace/breakpoint trap (core dumped)
------------------------------

Increasing the kernel maximum shared memory value allows to go further:

$ sudo sysctl -w kernel.shmmax=536870912

Reopening the file with EOG will hang again, this time displaying this error:

------------------------------
$ eog '/media/data/Pictures/France2018/DSC_2333.JPG'

(eog:17133): Gtk-WARNING **: 15:28:04.750: drawing failure for widget 'GtkDrawingArea': invalid value (typically too big) for the size of the input (surface, pattern, etc.)

(eog:17133): Gtk-WARNING **: 15:28:04.750: drawing failure for widget 'GtkOverlay': invalid value (typically too big) for the size of the input (surface, pattern, etc.)

(eog:17133): Gtk-WARNING **: 15:28:04.750: drawing failure for widget 'EogScrollView': invalid value (typically too big) for the size of the input (surface, pattern, etc.)

(eog:17133): Gtk-WARNING **: 15:28:04.750: drawing failure for widget 'GtkOverlay': invalid value (typically too big) for the size of the input (surface, pattern, etc.)

(eog:17133): Gtk-WARNING **: 15:28:04.750: drawing failure for widget 'GtkPaned': invalid value (typically too big) for the size of the input (surface, pattern, etc.)

(eog:17133): Gtk-WARNING **: 15:28:04.750: drawing failure for widget 'GtkBox': invalid value (typically too big) for the size of the input (surface, pattern, etc.)

(eog:17133): Gtk-WARNING **: 15:28:04.750: drawing failure for widget 'GtkBox': invalid value (typically too big) for the size of the input (surface, pattern, etc.)

(eog:17133): Gtk-WARNING **: 15:28:04.750: drawing failure for widget 'GtkBox': invalid value (typically too big) for the size of the input (surface, pattern, etc.)

(eog:17133): Gtk-WARNING **: 15:28:04.750: drawing failure for widget 'EogWindow': invalid value (typically too big) for the size of the input (surface, pattern, etc.)
------------------------------
(etc.)

I've uploaded the file used in this bug report here:
https://drive.google.com/file/d/1HW7QQNQ3nq19sgyRfyVbdsT_nit3Nj8l/view?usp=sharing

Expected behavior:
File should open, or at least a warning message should popup to explain that the file is too big to be displayed.

$ lsb_release -rd
Description: Ubuntu 18.04.1 LTS
Release: 18.04

$ uname -a
Linux mars 4.15.0-30-generic #32-Ubuntu SMP Thu Jul 26 17:42:43 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux

$ apt-cache policy eog
eog:
  Installed: 3.28.1-1
  Candidate: 3.28.1-1
  Version table:
 *** 3.28.1-1 500
        500 http://archive.ubuntu.com/ubuntu bionic/main amd64 Packages
        100 /var/lib/dpkg/status

ProblemType: Bug
DistroRelease: Ubuntu 18.04
Package: eog 3.28.1-1
ProcVersionSignature: Ubuntu 4.15.0-30.32-generic 4.15.18
Uname: Linux 4.15.0-30-generic x86_64
ApportVersion: 2.20.9-0ubuntu7.2
Architecture: amd64
CurrentDesktop: communitheme:ubuntu:GNOME
Date: Thu Aug 9 15:38:46 2018
EcryptfsInUse: Yes
InstallationDate: Installed on 2018-07-22 (18 days ago)
InstallationMedia: Ubuntu 18.04 LTS "Bionic Beaver" - Release amd64 (20180426)
SourcePackage: eog
UpgradeStatus: No upgrade log present (probably fresh install)

Revision history for this message
Theor (theor) wrote :
Theor (theor)
summary: - EOG crashes while opening a large file
+ EOG crashes when opening a large file
Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in eog (Ubuntu):
status: New → Confirmed
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.