From 66d495656348ae04b5ab725e0b44dad5f45e1a9b Mon Sep 17 00:00:00 2001 From: Sander Vrijders Date: Wed, 8 Feb 2017 18:36:01 +0100 Subject: lib, ipcpd: Comply to pedantic C99 With the changes in this commit Ouroboros will compile with the pedantic flag on when the standard is C99. The main problem was the used of unnamed structs and unions, which is C11. --- src/lib/btree.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'src/lib/btree.c') diff --git a/src/lib/btree.c b/src/lib/btree.c index 645e7c7a..38302dae 100644 --- a/src/lib/btree.c +++ b/src/lib/btree.c @@ -388,9 +388,12 @@ int btree_insert(struct btree * tree, void * val) { struct btnode * rgt = NULL; - struct key_val kv = {key, val}; + struct key_val kv; struct key_val med; + kv.key = key; + kv.val = val; + if (tree == NULL || val == NULL) return -EINVAL; -- cgit v1.2.3