From 3c5ce2c25c5c688ce23b8f72b0bba691dcd76264 Mon Sep 17 00:00:00 2001 From: Thomas Graf Date: Thu, 28 Aug 2014 14:40:50 +0200 Subject: [PATCH] ovsdb: Fix error leak for negative timeout and invalid until case Although the check for negative timeout is present, the error string is overwritten if an invalid "until" is found right after. This leaks an error string and results in not reporting the negative timeout back to the user even though it is encountered first. Signed-off-by: Thomas Graf Signed-off-by: Ben Pfaff --- ovsdb/execution.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/ovsdb/execution.c b/ovsdb/execution.c index 6314757c3..2be131db1 100644 --- a/ovsdb/execution.c +++ b/ovsdb/execution.c @@ -643,6 +643,8 @@ ovsdb_execute_wait(struct ovsdb_execution *x, struct ovsdb_parser *parser, } else { timeout_msec = LLONG_MAX; } + } + if (!error) { if (strcmp(json_string(until), "==") && strcmp(json_string(until), "!=")) { error = ovsdb_syntax_error(until, NULL, -- 2.20.1