diff options
author | Ben Pfaff <blp@ovn.org> | 2016-03-30 20:11:44 -0700 |
---|---|---|
committer | Ben Pfaff <blp@ovn.org> | 2016-03-30 22:38:49 -0700 |
commit | a6be657b299369da9780b67fe2f11caf835e6355 (patch) | |
tree | 2fc731b5f37eb4e1a15245ee7294c57244ea5612 /ovsdb/log.c | |
parent | 1021e19b1d729b1eff9e4ea91d71b5dec5d1261d (diff) | |
download | openvswitch-a6be657b299369da9780b67fe2f11caf835e6355.tar.gz |
ovsdb: Improve error message from ovsdb_log_open() open failure.
Previously, error messages ended up looking like:
ovsdb-tool: I/O error: create: $DBFILE failed (File exists)
which is hard to understand. This commit changes them to:
ovsdb-tool: I/O error: $DBFILE: create failed (File exists)
which makes more sense.
Signed-off-by: Ben Pfaff <blp@ovn.org>
Acked-by: Russell Bryant <russell@ovn.org>
Diffstat (limited to 'ovsdb/log.c')
-rw-r--r-- | ovsdb/log.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/ovsdb/log.c b/ovsdb/log.c index c1f822551..8004d3dce 100644 --- a/ovsdb/log.c +++ b/ovsdb/log.c @@ -114,7 +114,7 @@ ovsdb_log_open(const char *name, enum ovsdb_log_open_mode open_mode, fd = open(name, flags, 0666); if (fd < 0) { const char *op = open_mode == OVSDB_LOG_CREATE ? "create" : "open"; - error = ovsdb_io_error(errno, "%s: %s failed", op, name); + error = ovsdb_io_error(errno, "%s: %s failed", name, op); goto error_unlock; } |