From 9f612d4139f2f72a8796342dedd5a0044d4f2237 Mon Sep 17 00:00:00 2001 From: Emmanuele Bassi Date: Sun, 23 Oct 2022 18:39:04 +0100 Subject: jpeg: Bump up the memory limit to 1GB Let's play some more whack-a-mole. Fixes: #218 --- gdk-pixbuf/io-jpeg.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'gdk-pixbuf') diff --git a/gdk-pixbuf/io-jpeg.c b/gdk-pixbuf/io-jpeg.c index 6317e20d3..3841fc01d 100644 --- a/gdk-pixbuf/io-jpeg.c +++ b/gdk-pixbuf/io-jpeg.c @@ -1091,7 +1091,8 @@ gdk_pixbuf__jpeg_image_load_increment (gpointer data, rc = jpeg_read_header (cinfo, TRUE); context->src_initialized = TRUE; - cinfo->mem->max_memory_to_use = 300 * 1024 * 1024; + /* Limit to 1GB to avoid OOM with large images */ + cinfo->mem->max_memory_to_use = 1024 * 1024 * 1024; if (rc == JPEG_SUSPENDED) continue; -- cgit v1.2.1