summaryrefslogtreecommitdiff
path: root/src/pgtkselect.c
diff options
context:
space:
mode:
authorJindřich Makovička <makovick@gmail.com>2021-05-30 11:40:45 +0200
committerYuuki Harano <masm+github@masm11.me>2021-06-09 00:28:33 +0900
commit7673b6b9eb0af3add73e1614a466f142092b00aa (patch)
treee43ef547af2c4ad4ceca6aa4555ad01bee5b9c1f /src/pgtkselect.c
parentce7a78d0a8e033f04978b0c0762378ba13d3fa64 (diff)
downloademacs-7673b6b9eb0af3add73e1614a466f142092b00aa.tar.gz
* src/pgtkselect.c: Avoid Glib assertion warnings
Do not call g_object_get_qdata, when the clipboard has no owner, and obj is NULL. Just return Qnil immediately.
Diffstat (limited to 'src/pgtkselect.c')
-rw-r--r--src/pgtkselect.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/pgtkselect.c b/src/pgtkselect.c
index 8ab74744f39..447c839f459 100644
--- a/src/pgtkselect.c
+++ b/src/pgtkselect.c
@@ -518,7 +518,7 @@ On Nextstep, TERMINAL is unused. */)
obj = gtk_clipboard_get_owner (cb);
- return g_object_get_qdata (obj, quark_data) != NULL ? Qt : Qnil;
+ return obj && g_object_get_qdata (obj, quark_data) != NULL ? Qt : Qnil;
}