void-packages/srcpkgs/geis/patches/gcc-7.patch
cr6git 206dd73389 geis: fix cross compilation
Closes: #10621 [via git-merge-pr]
2018-01-11 10:03:38 +01:00

38 lines
1.3 KiB
Diff

From: Khem Raj <raj.khem@gmail.com>
Date: Mon, 24 Apr 2017 12:34:55 -0700
X-Dgit-Generated: 2.2.17-1.2 32cf7d865222f63ba5da5f79d340acf895ff9379
Subject: libgeis: Compare the first character of string to null
gcc7 wants to be specific when it comes to comparing characters
and strings
fixes
| ../../../../../../../workspace/sources/geis/libgeis/geis_v1.c: In function '_v1_subscribe_device':
| ../../../../../../../workspace/sources/geis/libgeis/geis_v1.c:613:20: error: comparison between pointer and zero character constant [-Werror=pointer-compare]
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Bug-Debian: https://bugs.debian.org/853415
---
--- libgeis/geis_v1.c
+++ libgeis/geis_v1.c
@@ -610,7 +610,7 @@ _v1_subscribe_device(GeisInstance instan
const char **gesture_list)
{
GeisStatus result = GEIS_UNKNOWN_ERROR;
- if (gesture_list == GEIS_ALL_GESTURES)
+ if (gesture_list[0][0] == GEIS_ALL_GESTURES)
{
geis_debug("subscribing device %d for all gestures", device_id);
}
@@ -757,7 +757,7 @@ geis_unsubscribe(GeisInstance instan
GeisGestureType *gesture_list)
{
GeisStatus status = GEIS_STATUS_NOT_SUPPORTED;
- if (gesture_list == GEIS_ALL_GESTURES)
+ if (gesture_list[0] == GEIS_ALL_GESTURES)
{
status = geis_subscription_deactivate(instance->subscription);
}