From: Daniel Mack Date: Thu, 14 Aug 2014 14:14:33 +0000 (+0200) Subject: test: test-kdbus: fix monitor and byebye tests X-Git-Tag: upstream/0.20140911.160207utc~53 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=a3c550f0592ec55b7706252eb1cef7ab3cdf7e49;p=platform%2Fcore%2Fsystem%2Fkdbus-bus.git test: test-kdbus: fix monitor and byebye tests Since commit 7015a1e6 ("prevent special-purpose connections from owning names or exchanging messages"), ioctl() calls return -EOPNOTSUPP they are issued to a handle of a inapproprate type. Follow this change in the test as well. --- diff --git a/test/test-kdbus.c b/test/test-kdbus.c index f0bf705..e4f5df5 100644 --- a/test/test-kdbus.c +++ b/test/test-kdbus.c @@ -476,7 +476,7 @@ static int check_byebye(struct kdbus_check_env *env) /* a 2nd try should result in -EALREADY */ ret = ioctl(conn->fd, KDBUS_CMD_BYEBYE, 0); - ASSERT_RETURN(ret == -1 && errno == EALREADY); + ASSERT_RETURN(ret == -1 && errno == EOPNOTSUPP); free_conn(conn); @@ -506,7 +506,7 @@ static int check_monitor(struct kdbus_check_env *env) /* check that we can acquire a name */ ret = ioctl(conn->fd, KDBUS_CMD_NAME_ACQUIRE, cmd_name); - ASSERT_RETURN(ret == -1 && errno == EPERM); + ASSERT_RETURN(ret == -1 && errno == EOPNOTSUPP); free_conn(conn);