summaryrefslogtreecommitdiff
path: root/src/libsystemd-network/test-ndisc-ra.c
diff options
context:
space:
mode:
authorYu Watanabe <watanabe.yu+github@gmail.com>2020-07-02 15:45:33 +0900
committerYu Watanabe <watanabe.yu+github@gmail.com>2020-07-02 16:58:06 +0900
commit7fa69c0a6f8a0e5425856d7f74c3e44834077f6b (patch)
tree93c38af19d310891580a0ead9eb80f54b7b224b4 /src/libsystemd-network/test-ndisc-ra.c
parent838d39af93e16e749ef90acf915a634b380abbf6 (diff)
downloadsystemd-7fa69c0a6f8a0e5425856d7f74c3e44834077f6b.tar.gz
dhcp6, radv: only accept valid ifindex
Diffstat (limited to 'src/libsystemd-network/test-ndisc-ra.c')
-rw-r--r--src/libsystemd-network/test-ndisc-ra.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/libsystemd-network/test-ndisc-ra.c b/src/libsystemd-network/test-ndisc-ra.c
index 7c6c4663f3..afd50d8fe3 100644
--- a/src/libsystemd-network/test-ndisc-ra.c
+++ b/src/libsystemd-network/test-ndisc-ra.c
@@ -159,8 +159,8 @@ static void test_radv(void) {
assert_se(ra);
assert_se(sd_radv_set_ifindex(NULL, 0) < 0);
- assert_se(sd_radv_set_ifindex(ra, 0) >= 0);
- assert_se(sd_radv_set_ifindex(ra, -1) >= 0);
+ assert_se(sd_radv_set_ifindex(ra, 0) < 0);
+ assert_se(sd_radv_set_ifindex(ra, -1) < 0);
assert_se(sd_radv_set_ifindex(ra, -2) < 0);
assert_se(sd_radv_set_ifindex(ra, 42) >= 0);