summaryrefslogtreecommitdiff
path: root/extra/xfce4-screenshooter/fs-25873-segfault-in-awesome-wm.patch
diff options
context:
space:
mode:
Diffstat (limited to 'extra/xfce4-screenshooter/fs-25873-segfault-in-awesome-wm.patch')
-rw-r--r--extra/xfce4-screenshooter/fs-25873-segfault-in-awesome-wm.patch21
1 files changed, 21 insertions, 0 deletions
diff --git a/extra/xfce4-screenshooter/fs-25873-segfault-in-awesome-wm.patch b/extra/xfce4-screenshooter/fs-25873-segfault-in-awesome-wm.patch
new file mode 100644
index 000000000..47e067144
--- /dev/null
+++ b/extra/xfce4-screenshooter/fs-25873-segfault-in-awesome-wm.patch
@@ -0,0 +1,21 @@
+--- a/lib/screenshooter-capture.c
++++ a/lib/screenshooter-capture.c
+@@ -381,6 +381,18 @@ static GdkPixbuf
+ rec_height += rectangle.y;
+ }
+
++ if (rec_x < 0)
++ {
++ rec_width = rec_width + rec_x;
++ rec_x = 0;
++ }
++
++ if (rec_y < 0)
++ {
++ rec_height = rec_height + rec_y;
++ rec_y = 0;
++ }
++
+ if (x_orig + rec_x + rec_width > gdk_screen_width ())
+ rec_width = gdk_screen_width () - x_orig - rec_x;
+