From: Ben Pfaff Date: Thu, 28 Jan 2010 18:09:15 +0000 (-0800) Subject: ovsdb-data: Allow spaces around '=' in key-value pairs. X-Git-Tag: v1.0.0~259^2~226 X-Git-Url: http://git.onelab.eu/?a=commitdiff_plain;h=9397a13f60a477a4244a305fd88845fd5dc36b22;p=sliver-openvswitch.git ovsdb-data: Allow spaces around '=' in key-value pairs. This allows a = b, a= b, a =b, etc. whereas before only a=b was accepted. --- diff --git a/lib/ovsdb-data.c b/lib/ovsdb-data.c index 1f3a89d63..8631016ff 100644 --- a/lib/ovsdb-data.c +++ b/lib/ovsdb-data.c @@ -843,8 +843,10 @@ parse_key_value(const char **s, const struct ovsdb_type *type, error = parse_atom_token(s, type->key_type, key); if (!error && type->value_type != OVSDB_TYPE_VOID) { + *s = skip_spaces(*s); if (**s == '=') { (*s)++; + *s = skip_spaces(*s); error = parse_atom_token(s, type->value_type, value); } else { error = xasprintf("%s: syntax error at \"%c\" expecting \"=\"",