parent
2bb960dbe1
commit
d4486513e9
111
ibus-1385349-segv-bus-proxy.patch
Normal file
111
ibus-1385349-segv-bus-proxy.patch
Normal file
@ -0,0 +1,111 @@
|
||||
From ddb7cb30f10b1d1e40ae4b6c46583941545412d8 Mon Sep 17 00:00:00 2001
|
||||
From: fujiwarat <takao.fujiwara1@gmail.com>
|
||||
Date: Wed, 26 Jul 2017 21:41:13 +0900
|
||||
Subject: [PATCH] bus: Fix SEGV in bus_panel_proxy_focus_in()
|
||||
|
||||
BUG=rhbz#1349148
|
||||
BUG=rhbz#1385349
|
||||
BUG=rhbz#1350291
|
||||
---
|
||||
bus/dbusimpl.c | 14 +++++++++++---
|
||||
bus/ibusimpl.c | 22 +++++++++++++++++++---
|
||||
2 files changed, 30 insertions(+), 6 deletions(-)
|
||||
|
||||
diff --git a/bus/dbusimpl.c b/bus/dbusimpl.c
|
||||
index b54ef81..4a60391 100644
|
||||
--- a/bus/dbusimpl.c
|
||||
+++ b/bus/dbusimpl.c
|
||||
@@ -2,7 +2,8 @@
|
||||
/* vim:set et sts=4: */
|
||||
/* ibus - The Input Bus
|
||||
* Copyright (C) 2008-2013 Peng Huang <shawn.p.huang@gmail.com>
|
||||
- * Copyright (C) 2008-2013 Red Hat, Inc.
|
||||
+ * Copyright (C) 2015-2017 Takao Fujiwara <takao.fujiwara1@gmail.com>
|
||||
+ * Copyright (C) 2008-2017 Red Hat, Inc.
|
||||
*
|
||||
* This library is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU Lesser General Public
|
||||
@@ -1464,13 +1465,20 @@ bus_dbus_impl_connection_filter_cb (GDBusConnection *dbus_connection,
|
||||
gboolean incoming,
|
||||
gpointer user_data)
|
||||
{
|
||||
+ BusDBusImpl *dbus;
|
||||
+ BusConnection *connection;
|
||||
+
|
||||
g_assert (G_IS_DBUS_CONNECTION (dbus_connection));
|
||||
g_assert (G_IS_DBUS_MESSAGE (message));
|
||||
g_assert (BUS_IS_DBUS_IMPL (user_data));
|
||||
|
||||
- BusDBusImpl *dbus = (BusDBusImpl *) user_data;
|
||||
- BusConnection *connection = bus_connection_lookup (dbus_connection);
|
||||
+ if (g_dbus_connection_is_closed (dbus_connection))
|
||||
+ return NULL;
|
||||
+
|
||||
+ dbus = (BusDBusImpl *) user_data;
|
||||
+ connection = bus_connection_lookup (dbus_connection);
|
||||
g_assert (connection != NULL);
|
||||
+ g_assert (BUS_IS_CONNECTION (connection));
|
||||
|
||||
if (incoming) {
|
||||
/* is incoming message */
|
||||
diff --git a/bus/ibusimpl.c b/bus/ibusimpl.c
|
||||
index f99307a..2d43ff6 100644
|
||||
--- a/bus/ibusimpl.c
|
||||
+++ b/bus/ibusimpl.c
|
||||
@@ -2,7 +2,8 @@
|
||||
/* vim:set et sts=4: */
|
||||
/* ibus - The Input Bus
|
||||
* Copyright (C) 2008-2013 Peng Huang <shawn.p.huang@gmail.com>
|
||||
- * Copyright (C) 2008-2013 Red Hat, Inc.
|
||||
+ * Copyright (C) 2015-2017 Takao Fujiwara <takao.fujiwara1@gmail.com>
|
||||
+ * Copyright (C) 2008-2017 Red Hat, Inc.
|
||||
*
|
||||
* This library is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU Lesser General Public
|
||||
@@ -323,11 +324,14 @@ _dbus_name_owner_changed_cb (BusDBusImpl *dbus,
|
||||
g_assert (new_name != NULL);
|
||||
g_assert (BUS_IS_IBUS_IMPL (ibus));
|
||||
|
||||
- if (g_strcmp0 (name, IBUS_SERVICE_PANEL) == 0) {
|
||||
+ do {
|
||||
+ if (g_strcmp0 (name, IBUS_SERVICE_PANEL) != 0)
|
||||
+ break;
|
||||
if (g_strcmp0 (new_name, "") != 0) {
|
||||
/* a Panel process is started. */
|
||||
BusConnection *connection;
|
||||
BusInputContext *context = NULL;
|
||||
+ GDBusConnection *dbus_connection = NULL;
|
||||
|
||||
if (ibus->panel != NULL) {
|
||||
ibus_proxy_destroy ((IBusProxy *) ibus->panel);
|
||||
@@ -338,6 +342,18 @@ _dbus_name_owner_changed_cb (BusDBusImpl *dbus,
|
||||
connection = bus_dbus_impl_get_connection_by_name (BUS_DEFAULT_DBUS, new_name);
|
||||
g_return_if_fail (connection != NULL);
|
||||
|
||||
+ dbus_connection = bus_connection_get_dbus_connection (connection);
|
||||
+
|
||||
+ /* rhbz#1349148 rhbz#1385349
|
||||
+ * Avoid SEGV of BUS_IS_PANEL_PROXY (ibus->panel)
|
||||
+ * This function is called during destroying the connection
|
||||
+ * in this case? */
|
||||
+ if (dbus_connection == NULL ||
|
||||
+ g_dbus_connection_is_closed (dbus_connection)) {
|
||||
+ new_name = "";
|
||||
+ break;
|
||||
+ }
|
||||
+
|
||||
ibus->panel = bus_panel_proxy_new (connection);
|
||||
|
||||
g_signal_connect (ibus->panel,
|
||||
@@ -366,7 +382,7 @@ _dbus_name_owner_changed_cb (BusDBusImpl *dbus,
|
||||
}
|
||||
}
|
||||
}
|
||||
- }
|
||||
+ } while (0);
|
||||
|
||||
bus_ibus_impl_component_name_owner_changed (ibus, name, old_name, new_name);
|
||||
}
|
||||
--
|
||||
2.9.3
|
||||
|
@ -619,15 +619,19 @@ index 1d105fd..95912bf 100644
|
||||
--
|
||||
2.9.3
|
||||
|
||||
From 76a83df1ab2aca4063968b2dd5300c64979e9496 Mon Sep 17 00:00:00 2001
|
||||
From bc0f91342c6f3a6e554493af9430d634d906ee19 Mon Sep 17 00:00:00 2001
|
||||
From: fujiwarat <takao.fujiwara1@gmail.com>
|
||||
Date: Wed, 19 Jul 2017 20:48:17 +0900
|
||||
Date: Tue, 25 Jul 2017 12:00:14 +0900
|
||||
Subject: [PATCH] ui/gtk3: Fix SEGV of IBusEmojier on de_DE.UTF-8
|
||||
|
||||
de's decimal_point is ',' instead of '.' and failed to load the
|
||||
CSS data in Gtk.CssProvider.load_from_data(), launched null
|
||||
window of emojis and finally caused a SEGV due to the null window.
|
||||
This also fixes some memory leaks.
|
||||
|
||||
BUG=rhbz#1471079
|
||||
|
||||
Review URL: https://codereview.appspot.com/323310043
|
||||
---
|
||||
src/ibusemoji.c | 1 +
|
||||
ui/gtk3/emojier.vala | 33 ++++++++++++++++++++++++++-------
|
||||
@ -727,6 +731,41 @@ index 95912bf..9df59ac 100644
|
||||
--
|
||||
2.9.3
|
||||
|
||||
From 4134113a1ae30534367a9ca729c7f36a0a8e3662 Mon Sep 17 00:00:00 2001
|
||||
From: fujiwarat <takao.fujiwara1@gmail.com>
|
||||
Date: Thu, 27 Jul 2017 14:07:00 +0900
|
||||
Subject: [PATCH] ui/gtk3: Fix SEGV of XKeysymToKeycode() on Wayland
|
||||
|
||||
BUG=rhbz#1368593
|
||||
---
|
||||
ui/gtk3/application.vala | 4 ++++
|
||||
1 file changed, 4 insertions(+)
|
||||
|
||||
diff --git a/ui/gtk3/application.vala b/ui/gtk3/application.vala
|
||||
index 5ae6e83..fa80272 100644
|
||||
--- a/ui/gtk3/application.vala
|
||||
+++ b/ui/gtk3/application.vala
|
||||
@@ -3,6 +3,7 @@
|
||||
* ibus - The Input Bus
|
||||
*
|
||||
* Copyright(c) 2011 Peng Huang <shawn.p.huang@gmail.com>
|
||||
+ * Copyright(c) 2017 Takao Fujiwara <takao.fujiwara1@gmail.com>
|
||||
*
|
||||
* This library is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU Lesser General Public
|
||||
@@ -99,6 +100,9 @@ class Application {
|
||||
}
|
||||
|
||||
public static void main(string[] argv) {
|
||||
+ // for Gdk.X11.get_default_xdisplay()
|
||||
+ Gdk.set_allowed_backends("x11");
|
||||
+
|
||||
Application app = new Application(argv);
|
||||
app.run();
|
||||
}
|
||||
--
|
||||
2.9.3
|
||||
|
||||
From 2686b46b29e12b4408033568a898949a731b7938 Mon Sep 17 00:00:00 2001
|
||||
From: fujiwarat <takao.fujiwara1@gmail.com>
|
||||
Date: Wed, 19 Jul 2017 21:02:20 +0900
|
||||
|
@ -30,7 +30,7 @@
|
||||
|
||||
Name: ibus
|
||||
Version: 1.5.16
|
||||
Release: 5%{?dist}
|
||||
Release: 6%{?dist}
|
||||
Summary: Intelligent Input Bus for Linux OS
|
||||
License: LGPLv2+
|
||||
Group: System Environment/Libraries
|
||||
@ -42,6 +42,8 @@ Source2: %{name}.conf.5
|
||||
# Upstreamed patches.
|
||||
# Patch0: %%{name}-HEAD.patch
|
||||
Patch0: %{name}-HEAD.patch
|
||||
# Under testing #1349148 #1385349 #1350291
|
||||
Patch1: %{name}-1385349-segv-bus-proxy.patch
|
||||
|
||||
BuildRequires: gettext-devel
|
||||
BuildRequires: libtool
|
||||
@ -236,6 +238,7 @@ The ibus-devel-docs package contains developer documentation for IBus
|
||||
# %%patch0 -p1
|
||||
# cp client/gtk2/ibusimcontext.c client/gtk3/ibusimcontext.c ||
|
||||
%patch0 -p1
|
||||
%patch1 -p1
|
||||
|
||||
%build
|
||||
#autoreconf -f -i -v
|
||||
@ -430,6 +433,10 @@ gtk-query-immodules-3.0-%{__isa_bits} --update-cache &> /dev/null || :
|
||||
%{_datadir}/gtk-doc/html/*
|
||||
|
||||
%changelog
|
||||
* Thu Jul 27 2017 Takao Fujiwara <tfujiwar@redhat.com> - 1.5.16-6
|
||||
- Fixed some SEGVs #1349148 #1385349 #1350291 #1368593
|
||||
Added 1385349-segv-bus-proxy.patch
|
||||
|
||||
* Wed Jul 26 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.5.16-5
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user