- Recreate the ibus-HEAD.patch from upstream git source tree.
- The new patch fixes ibus-x11 segfault (#485661).
This commit is contained in:
parent
8b3cdeba91
commit
7cae023bf0
173
ibus-HEAD.patch
173
ibus-HEAD.patch
@ -1,3 +1,16 @@
|
||||
diff --git a/autogen.sh b/autogen.sh
|
||||
index d9a7a56..c34acab 100755
|
||||
--- a/autogen.sh
|
||||
+++ b/autogen.sh
|
||||
@@ -4,7 +4,7 @@ set -x
|
||||
|
||||
autopoint --force
|
||||
libtoolize --automake --copy --force
|
||||
-gtkdocize #--flavour=no-tmpl
|
||||
+gtkdocize --copy #--flavour=no-tmpl
|
||||
aclocal -I m4 --force
|
||||
autoheader --force
|
||||
automake --add-missing --copy --force
|
||||
diff --git a/bus/engineproxy.c b/bus/engineproxy.c
|
||||
index 6fc111f..647845b 100644
|
||||
--- a/bus/engineproxy.c
|
||||
@ -507,6 +520,127 @@ index 56f593a..75b02a5 100644
|
||||
{
|
||||
*contexts = info_list;
|
||||
*n_contexts = G_N_ELEMENTS (info_list);
|
||||
diff --git a/client/x11/main.c b/client/x11/main.c
|
||||
index 5ef9f30..6437d50 100644
|
||||
--- a/client/x11/main.c
|
||||
+++ b/client/x11/main.c
|
||||
@@ -327,7 +327,7 @@ xim_create_ic (XIMS xims, IMChangeICStruct *call_data)
|
||||
x11ic->icid = call_data->icid;
|
||||
x11ic->connect_id = call_data->connect_id;
|
||||
x11ic->conn = (X11ICONN *)g_hash_table_lookup (_connections,
|
||||
- GINT_TO_POINTER (call_data->connect_id));
|
||||
+ GINT_TO_POINTER ((gint) call_data->connect_id));
|
||||
if (x11ic->conn == NULL) {
|
||||
g_slice_free (X11IC, x11ic);
|
||||
g_return_val_if_reached (0);
|
||||
@@ -383,7 +383,7 @@ xim_destroy_ic (XIMS xims, IMChangeICStruct *call_data)
|
||||
call_data->icid, call_data->connect_id);
|
||||
|
||||
x11ic = (X11IC *)g_hash_table_lookup (_x11_ic_table,
|
||||
- GINT_TO_POINTER (call_data->icid));
|
||||
+ GINT_TO_POINTER ((gint) call_data->icid));
|
||||
g_return_val_if_fail (x11ic != NULL, 0);
|
||||
|
||||
if (x11ic->context) {
|
||||
@@ -393,7 +393,7 @@ xim_destroy_ic (XIMS xims, IMChangeICStruct *call_data)
|
||||
}
|
||||
|
||||
g_hash_table_remove (_x11_ic_table,
|
||||
- GINT_TO_POINTER (call_data->icid));
|
||||
+ GINT_TO_POINTER ((gint) call_data->icid));
|
||||
x11ic->conn->clients = g_list_remove (x11ic->conn->clients, (gconstpointer)x11ic);
|
||||
|
||||
g_free (x11ic->preedit_string);
|
||||
@@ -418,7 +418,7 @@ xim_set_ic_focus (XIMS xims, IMChangeFocusStruct *call_data)
|
||||
call_data->icid, call_data->connect_id);
|
||||
|
||||
x11ic = (X11IC *) g_hash_table_lookup (_x11_ic_table,
|
||||
- GINT_TO_POINTER (call_data->icid));
|
||||
+ GINT_TO_POINTER ((gint) call_data->icid));
|
||||
g_return_val_if_fail (x11ic != NULL, 0);
|
||||
|
||||
ibus_input_context_focus_in (x11ic->context);
|
||||
@@ -436,7 +436,7 @@ xim_unset_ic_focus (XIMS xims, IMChangeFocusStruct *call_data)
|
||||
call_data->icid, call_data->connect_id);
|
||||
|
||||
x11ic = (X11IC *) g_hash_table_lookup (_x11_ic_table,
|
||||
- GINT_TO_POINTER (call_data->icid));
|
||||
+ GINT_TO_POINTER ((gint) call_data->icid));
|
||||
g_return_val_if_fail (x11ic != NULL, 0);
|
||||
|
||||
ibus_input_context_focus_out (x11ic->context);
|
||||
@@ -456,7 +456,7 @@ xim_forward_event (XIMS xims, IMForwardEventStruct *call_data)
|
||||
call_data->icid, call_data->connect_id);
|
||||
|
||||
x11ic = (X11IC *) g_hash_table_lookup (_x11_ic_table,
|
||||
- GINT_TO_POINTER (call_data->icid));
|
||||
+ GINT_TO_POINTER ((gint) call_data->icid));
|
||||
g_return_val_if_fail (x11ic != NULL, 0);
|
||||
|
||||
xevent = (XKeyEvent*) &(call_data->event);
|
||||
@@ -504,7 +504,7 @@ xim_open (XIMS xims, IMOpenStruct *call_data)
|
||||
call_data->connect_id);
|
||||
|
||||
conn = (X11ICONN *) g_hash_table_lookup (_connections,
|
||||
- GINT_TO_POINTER (call_data->connect_id));
|
||||
+ GINT_TO_POINTER ((gint) call_data->connect_id));
|
||||
g_return_val_if_fail (conn == NULL, 0);
|
||||
|
||||
conn = g_slice_new0 (X11ICONN);
|
||||
@@ -552,7 +552,7 @@ xim_close (XIMS ims, IMCloseStruct *call_data)
|
||||
call_data->connect_id);
|
||||
|
||||
conn = (X11ICONN *) g_hash_table_lookup (_connections,
|
||||
- GINT_TO_POINTER (call_data->connect_id));
|
||||
+ GINT_TO_POINTER ((gint) call_data->connect_id));
|
||||
g_return_val_if_fail (conn != NULL, 0);
|
||||
|
||||
g_list_foreach (conn->clients, _free_ic, NULL);
|
||||
@@ -560,7 +560,7 @@ xim_close (XIMS ims, IMCloseStruct *call_data)
|
||||
g_list_free (conn->clients);
|
||||
|
||||
g_hash_table_remove (_connections,
|
||||
- GINT_TO_POINTER (call_data->connect_id));
|
||||
+ GINT_TO_POINTER ((gint) call_data->connect_id));
|
||||
|
||||
g_slice_free (X11ICONN, conn);
|
||||
|
||||
@@ -621,7 +621,7 @@ xim_set_ic_values (XIMS xims, IMChangeICStruct *call_data)
|
||||
call_data->icid, call_data->connect_id);
|
||||
|
||||
x11ic = (X11IC *) g_hash_table_lookup (_x11_ic_table,
|
||||
- GINT_TO_POINTER (call_data->icid));
|
||||
+ GINT_TO_POINTER ((gint) call_data->icid));
|
||||
g_return_val_if_fail (x11ic != NULL, 0);
|
||||
|
||||
i = _xim_store_ic_values (x11ic, call_data);
|
||||
@@ -643,7 +643,7 @@ xim_get_ic_values (XIMS xims, IMChangeICStruct *call_data)
|
||||
call_data->icid, call_data->connect_id);
|
||||
|
||||
x11ic = (X11IC *) g_hash_table_lookup (_x11_ic_table,
|
||||
- GINT_TO_POINTER (call_data->icid));
|
||||
+ GINT_TO_POINTER ((gint) call_data->icid));
|
||||
g_return_val_if_fail (x11ic != NULL, 0);
|
||||
|
||||
XICAttribute *ic_attr = call_data->ic_attr;
|
||||
@@ -670,7 +670,7 @@ xim_reset_ic (XIMS xims, IMResetICStruct *call_data)
|
||||
call_data->icid, call_data->connect_id);
|
||||
|
||||
x11ic = (X11IC *) g_hash_table_lookup (_x11_ic_table,
|
||||
- GINT_TO_POINTER (call_data->icid));
|
||||
+ GINT_TO_POINTER ((gint) call_data->icid));
|
||||
g_return_val_if_fail (x11ic != NULL, 0);
|
||||
|
||||
ibus_input_context_reset (x11ic->context);
|
||||
@@ -981,7 +981,7 @@ _xim_init_IMdkit ()
|
||||
static void
|
||||
_atexit_cb ()
|
||||
{
|
||||
- if (_bus) {
|
||||
+ if (_bus && ibus_bus_is_connected (_bus)) {
|
||||
ibus_bus_exit(_bus, False);
|
||||
}
|
||||
}
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index 7481739..4437fd2 100644
|
||||
--- a/configure.ac
|
||||
@ -521,7 +655,7 @@ index 7481739..4437fd2 100644
|
||||
|
||||
PKG_CHECK_MODULES(GCONF,
|
||||
diff --git a/ibus.spec.in b/ibus.spec.in
|
||||
index 65dfced..d9d5dba 100644
|
||||
index 65dfced..908ddbd 100644
|
||||
--- a/ibus.spec.in
|
||||
+++ b/ibus.spec.in
|
||||
@@ -20,7 +20,7 @@ BuildRequires: libtool
|
||||
@ -583,6 +717,24 @@ index 65dfced..d9d5dba 100644
|
||||
|
||||
%package devel
|
||||
Summary: Development tools for ibus
|
||||
@@ -100,7 +108,7 @@ desktop-file-install --delete-original \
|
||||
%clean
|
||||
rm -rf $RPM_BUILD_ROOT
|
||||
|
||||
-%post
|
||||
+%post libs
|
||||
/sbin/ldconfig
|
||||
update-desktop-database -q
|
||||
%{_sbindir}/alternatives --install %{_sysconfdir}/X11/xinit/xinputrc xinputrc %{_xinputconf} 83 || :
|
||||
@@ -108,7 +116,7 @@ update-desktop-database -q
|
||||
%post gtk
|
||||
%{_bindir}/update-gtk-immodules %{_host} || :
|
||||
|
||||
-%postun
|
||||
+%postun libs
|
||||
/sbin/ldconfig
|
||||
update-desktop-database -q
|
||||
if [ "$1" = "0" ]; then
|
||||
@@ -123,13 +131,10 @@ fi
|
||||
%files -f %{name}.lang
|
||||
%defattr(-,root,root,-)
|
||||
@ -660,10 +812,20 @@ index 32ba998..63d6c0e 100644
|
||||
def FocusIn(self): pass
|
||||
|
||||
diff --git a/src/ibusbus.c b/src/ibusbus.c
|
||||
index 9965761..0ebdf66 100644
|
||||
index 9965761..52631e8 100644
|
||||
--- a/src/ibusbus.c
|
||||
+++ b/src/ibusbus.c
|
||||
@@ -639,15 +639,20 @@ ibus_bus_exit (IBusBus *bus,
|
||||
@@ -149,6 +149,9 @@ _connection_destroy_cb (IBusConnection *connection,
|
||||
priv = IBUS_BUS_GET_PRIVATE (bus);
|
||||
|
||||
g_assert (priv->connection == connection);
|
||||
+ g_signal_handlers_disconnect_by_func (priv->connection,
|
||||
+ G_CALLBACK (_connection_destroy_cb),
|
||||
+ bus);
|
||||
g_object_unref (priv->connection);
|
||||
priv->connection = NULL;
|
||||
|
||||
@@ -639,12 +642,15 @@ ibus_bus_exit (IBusBus *bus,
|
||||
{
|
||||
g_assert (IBUS_IS_BUS (bus));
|
||||
|
||||
@ -680,11 +842,6 @@ index 9965761..0ebdf66 100644
|
||||
G_TYPE_BOOLEAN, &restart,
|
||||
G_TYPE_INVALID,
|
||||
G_TYPE_INVALID);
|
||||
+ ibus_connection_flush (priv->connection);
|
||||
+
|
||||
return result;
|
||||
}
|
||||
|
||||
diff --git a/src/ibuslookuptable.c b/src/ibuslookuptable.c
|
||||
index e2935b8..37342c5 100644
|
||||
--- a/src/ibuslookuptable.c
|
||||
|
@ -3,7 +3,7 @@
|
||||
%define mod_path ibus-1.1
|
||||
Name: ibus
|
||||
Version: 1.1.0.20090211
|
||||
Release: 5%{?dist}
|
||||
Release: 6%{?dist}
|
||||
Summary: Intelligent Input Bus for Linux OS
|
||||
License: LGPLv2+
|
||||
Group: System Environment/Libraries
|
||||
@ -180,6 +180,10 @@ fi
|
||||
%{_libdir}/pkgconfig/*
|
||||
|
||||
%changelog
|
||||
* Mon Feb 16 2009 Huang Peng <shawn.p.huang@gmail.com> - 1.1.0.20090211-6
|
||||
- Recreate the ibus-HEAD.patch from upstream git source tree.
|
||||
- The new patch fixes ibus-x11 segfault (#485661).
|
||||
|
||||
* Sun Feb 15 2009 Huang Peng <shawn.p.huang@gmail.com> - 1.1.0.20090211-5
|
||||
- Recreate the ibus-HEAD.patch from upstream git source tree.
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user