[gnome-remote-desktop/gnome-42] clipboard: Turn a condition into an assertion



commit 44d90699e7431164b4d87e7c82b8446b5ac2a9a0
Author: Pascal Nowack <Pascal Nowack gmx de>
Date:   Tue Aug 23 05:33:01 2022 +0200

    clipboard: Turn a condition into an assertion
    
    This condition should here always be true.

 src/grd-clipboard.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
---
diff --git a/src/grd-clipboard.c b/src/grd-clipboard.c
index 3074621c..8bfb02f0 100644
--- a/src/grd-clipboard.c
+++ b/src/grd-clipboard.c
@@ -311,8 +311,7 @@ grd_clipboard_request_server_content_for_mime_type_async (GrdClipboard *clipboar
 
   g_return_if_fail (klass->submit_requested_server_content);
 
-  if (!priv->enabled)
-    return;
+  g_assert (priv->enabled);
 
   g_debug ("Clipboard[SelectionRead]: Requesting data from servers clipboard"
            " (mime type: %s)", grd_mime_type_to_string (mime_type));


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