diff options
author | Pablo Neira Ayuso <pablo@netfilter.org> | 2013-03-04 15:41:47 +0100 |
---|---|---|
committer | Pablo Neira Ayuso <pablo@netfilter.org> | 2013-03-04 15:41:47 +0100 |
commit | 8d644deb1d3f1302c879ead7845ef0be674c99ec (patch) | |
tree | 7ff6a48ce354f6f5208fe43a3f919d369476411c /qa | |
parent | 10e84b5551e3606612b24f2ea54024d5687bc5bd (diff) |
qa: fix bogus eror in test_api
Use buf[32] as struct nfct_attr_grp_ipv6 is 32 bytes long. That fixes:
== validate set grp API ==
ERROR: set/get operations don't match for attribute 2 (2 != 1)
ERROR: set/get operations don't match for attribute 3 (3 != 1)
ERROR: set/get operations don't match for attribute 8 (8 != 1)
Shows up with gcc 4.7.1.
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Diffstat (limited to 'qa')
-rw-r--r-- | qa/test_api.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/qa/test_api.c b/qa/test_api.c index cdd128a..6811ea7 100644 --- a/qa/test_api.c +++ b/qa/test_api.c @@ -234,7 +234,7 @@ int main(void) printf("== test get grp API ==\n"); ret = fork(); if (ret == 0) { - char buf[16]; + char buf[32]; /* IPv6 group address is 16 bytes * 2 */ for (i=0; i<ATTR_GRP_MAX; i++) nfct_get_attr_grp(ct2, i, buf); @@ -248,7 +248,7 @@ int main(void) ret = fork(); if (ret == 0) { for (i=0; i<ATTR_GRP_MAX; i++) { - char buf[16]; + char buf[32]; /* IPv6 group address is 16 bytes */ data[0] = (uint8_t) i; nfct_set_attr_grp(ct2, i, data); |