projects
/
openvswitch
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
bca5120
)
ovsdb: Explicitly ignore sscanf() return value in is_valid_version().
author
Ben Pfaff
<blp@nicira.com>
Wed, 23 Feb 2011 21:13:44 +0000
(13:13 -0800)
committer
Ben Pfaff
<blp@nicira.com>
Wed, 23 Feb 2011 23:14:44 +0000
(15:14 -0800)
The return value isn't interesting here: it will always be 0.
Coverity #10698.
ovsdb/ovsdb.c
patch
|
blob
|
history
diff --git
a/ovsdb/ovsdb.c
b/ovsdb/ovsdb.c
index 2a54a7b908b8283fe96d3b323cdaf7b80b8b90b5..e76544e36253347da7a33e7dcf9c20207d7ab345 100644
(file)
--- a/
ovsdb/ovsdb.c
+++ b/
ovsdb/ovsdb.c
@@
-123,7
+123,7
@@
static bool
is_valid_version(const char *s)
{
int n = -1;
-
sscanf(s, "%*[0-9].%*[0-9].%*[0-9]%n", &n
);
+
ignore(sscanf(s, "%*[0-9].%*[0-9].%*[0-9]%n", &n)
);
return n != -1 && s[n] == '\0';
}