[gnome-shell] screenshot: Clean up when creating stream failed



commit fec745ffb816fb9ca1ac9b7776f4e785826982bc
Author: Florian Müllner <fmuellner gnome org>
Date:   Mon Jan 25 12:12:44 2021 +0100

    screenshot: Clean up when creating stream failed
    
    Otherwise the tracked screenshot operation will block all future
    requests from the same sender.
    
    https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3618
    
    Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1589>

 js/ui/screenshot.js | 2 ++
 1 file changed, 2 insertions(+)
---
diff --git a/js/ui/screenshot.js b/js/ui/screenshot.js
index 05120e1a22..8a92c62130 100644
--- a/js/ui/screenshot.js
+++ b/js/ui/screenshot.js
@@ -109,6 +109,7 @@ var ScreenshotService = class {
                 return [stream, file];
             } catch (e) {
                 invocation.return_gerror(e);
+                this._removeShooterForSender(invocation.get_sender());
                 return [null, null];
             }
         }
@@ -126,6 +127,7 @@ var ScreenshotService = class {
         }
 
         invocation.return_gerror(err);
+        this._removeShooterForSender(invocation.get_sender());
         return [null, null];
     }
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]