app-i18n/skkfep: fix segfault
authorAkinori Hattori <hattya@gentoo.org>
Sun, 25 Jun 2017 05:18:38 +0000 (14:18 +0900)
committerAkinori Hattori <hattya@gentoo.org>
Sun, 25 Jun 2017 05:18:38 +0000 (14:18 +0900)
Package-Manager: Portage-2.3.6, Repoman-2.3.1

app-i18n/skkfep/files/skkfep-system-dic.patch [new file with mode: 0644]
app-i18n/skkfep/skkfep-0.87-r1.ebuild

diff --git a/app-i18n/skkfep/files/skkfep-system-dic.patch b/app-i18n/skkfep/files/skkfep-system-dic.patch
new file mode 100644 (file)
index 0000000..ba57a2a
--- /dev/null
@@ -0,0 +1,13 @@
+--- a/kkconv.c
++++ b/kkconv.c
+@@ -660,7 +660,9 @@
+               flushOut(l);
+ #ifdef USE_SERVER
+               if (!CandFromServer) {
+-                      selectCand(FirstCandEntry,CurrentCand);
++                      if (FirstCandEntry != NULL) {
++                              selectCand(FirstCandEntry,CurrentCand);
++                      }
+               }
+               else if (NetLearnMode != LearnOff) {
+                       if (CurrentCand->dicitem == NULL) {
index 57a0760d5339ae6c1a3ccf23f8417c4cdfad1eb8..a3e53f72d619e2133283f4374421d4e45052064f 100644 (file)
@@ -20,7 +20,10 @@ DEPEND="sys-apps/sed
 RDEPEND="sys-libs/ncurses:=
        app-i18n/skk-jisyo"
 
-PATCHES=( "${FILESDIR}"/${PN}-gentoo.patch )
+PATCHES=(
+       "${FILESDIR}"/${PN}-gentoo.patch
+       "${FILESDIR}"/${PN}-system-dic.patch
+)
 DOCS=( README HISTORY TODO )
 
 src_prepare() {