File: window-commands-fix-crash-when-taking-screenshot.patch

package info (click to toggle)
epiphany-browser 48.5-3
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 27,172 kB
  • sloc: ansic: 75,495; javascript: 7,332; xml: 686; python: 177; sh: 77; makefile: 14
file content (30 lines) | stat: -rw-r--r-- 1,174 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
From: Michael Catanzaro <mcatanzaro@redhat.com>
Date: Fri, 18 Jul 2025 16:57:35 -0500
Subject: window-commands: fix crash when taking screenshot

This is a regression from f87d5f9eee23b8b5e56b5390ff2ba34e207a93c0. I
changed save_dialog_cb() to receive an async data struct as user data
instead of an EphyEmbed, but turns out this callback is used in two
places and I only updated one of the two call sites. Oops.

(cherry picked from commit e018dacb8ebe68e50a8d36d7053f68681ba17154)

Co-authored-by: Michael Catanzaro <mcatanzaro@redhat.com>
Origin: upstream, 48.6, commit:64e614e9f6ae04c5cc33730692e98610f022a052
---
 src/window-commands.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/window-commands.c b/src/window-commands.c
index 8f5f773..1951b67 100644
--- a/src/window-commands.c
+++ b/src/window-commands.c
@@ -2638,7 +2638,7 @@ window_cmd_screenshot (GSimpleAction *action,
                         GTK_WINDOW (window),
                         NULL,
                         (GAsyncReadyCallback)save_dialog_cb,
-                        embed);
+                        save_dialog_async_data_new (embed, suggested_filename));
 }
 
 void