Package: fcitx / 1:4.2.9.1-6

0011-fix-xshape-version-check.patch Patch series | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
From: Weng Xuetian <wengxt@gmail.com>
Date: Mon, 17 Oct 2016 16:18:01 -0700
Subject: fix xshape version check

we want to check (x.y) >= (1.1), not (x>=1 && y>=1).
---
 src/ui/classic/classicui.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/ui/classic/classicui.c b/src/ui/classic/classicui.c
index 66af223..049cfc8 100644
--- a/src/ui/classic/classicui.c
+++ b/src/ui/classic/classicui.c
@@ -128,7 +128,7 @@ void* ClassicUICreate(FcitxInstance* instance)
     int dummy1 = 0, dummy2 = 0, major, minor;
     if (XShapeQueryExtension(classicui->dpy, &dummy1, &dummy2) == True &&
         XShapeQueryVersion(classicui->dpy, &major, &minor)) {
-        if (major >=1 && minor >= 1) {
+        if (major > 1 || (major == 1 && minor >= 1)) {
             classicui->hasXShape = true;
         }
     }