1 Star 0 Fork 15

问书/ibus_bak

forked from src-anolis-os/ibus 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
ibus-1470673-emoji-warn-instead-assert.patch 1.73 KB
一键复制 编辑 原始数据 按行查看 历史
张彬琛 提交于 2021-01-20 20:41 . import ibus-1.5.19-11.el8.src.rpm
From 0f5084e07c215d74adc4eeeda40b374855cce59a Mon Sep 17 00:00:00 2001
From: fujiwarat <takao.fujiwara1@gmail.com>
Date: Fri, 11 Jan 2019 12:56:42 +0900
Subject: [PATCH] src/ibuscomposetable: Replace assert with warning for
.XCompose
BUG=rhbz#1470673
---
src/ibuscomposetable.c | 12 +++++++-----
1 file changed, 7 insertions(+), 5 deletions(-)
diff --git a/src/ibuscomposetable.c b/src/ibuscomposetable.c
index b843e7e1..1c0ece41 100644
--- a/src/ibuscomposetable.c
+++ b/src/ibuscomposetable.c
@@ -1,7 +1,7 @@
/* -*- mode: C; c-basic-offset: 4; indent-tabs-mode: nil; -*- */
/* ibus - The Input Bus
* Copyright (C) 2013-2014 Peng Huang <shawn.p.huang@gmail.com>
- * Copyright (C) 2013-2018 Takao Fujiwara <takao.fujiwara1@gmail.com>
+ * Copyright (C) 2013-2019 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
@@ -98,14 +98,16 @@ parse_compose_value (IBusComposeData *compose_data,
uch = words[1][1];
/* The escaped string "\"" is separated with '\\' and '"'. */
- if (uch == '\0' && words[2][0] == '"')
+ if (uch == '\0' && words[2][0] == '"') {
uch = '"';
/* The escaped octal */
- else if (uch >= '0' && uch <= '8')
+ } else if (uch >= '0' && uch <= '8') {
uch = g_ascii_strtoll(words[1] + 1, NULL, 8);
/* If we need to handle other escape sequences. */
- else if (uch != '\\')
- g_assert_not_reached ();
+ } else if (uch != '\\') {
+ g_warning ("Invalid backslash: %s: %s", val, line);
+ goto fail;
+ }
}
if (g_utf8_get_char (g_utf8_next_char (words[1])) > 0) {
--
2.21.0
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/Weisson/ibus_bak.git
git@gitee.com:Weisson/ibus_bak.git
Weisson
ibus_bak
ibus_bak
a8

搜索帮助