summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: b71f47a)
raw | patch | inline | side by side (parent: b71f47a)
author | Sebastian Harl <sh@tokkee.org> | |
Sun, 23 Feb 2014 04:25:56 +0000 (20:25 -0800) | ||
committer | Sebastian Harl <sh@tokkee.org> | |
Sun, 23 Feb 2014 04:25:56 +0000 (20:25 -0800) |
The compiler does not know that fail aborts the test program and clang
(correctly) complains that the variable ('m' in this case) might be used
uninitialized afterwards.
(correctly) complains that the variable ('m' in this case) might be used
uninitialized afterwards.
t/core/store_lookup_test.c | patch | blob | history |
index 48bb4832f4b81e723743d27cefd1c705e40e93a5..74274f80c0cf0f8fc6ec75b7a4dcc909c1c19449 100644 (file)
else if (! strcmp(golden_data[i].op, "AND"))
m = sdb_store_con_matcher(golden_data[i].left,
golden_data[i].right);
- else
+ else {
fail("INTERNAL ERROR: unexpected operator %s", golden_data[i].op);
+ continue;
+ }
#define TO_NAME(v) (((v) == always) ? "always" \
: ((v) == never) ? "never" : "<unknown>")