summaryrefslogtreecommitdiff
path: root/ovsdb/transaction.h
diff options
context:
space:
mode:
authorJustin Pettit <jpettit@nicira.com>2011-02-23 10:39:21 -0800
committerJustin Pettit <jpettit@nicira.com>2011-02-23 11:08:20 -0800
commit5f8e32136eacbc91b7422b17d8208a64cfb3b8b9 (patch)
tree9fa2fb9a69d6130d9b149d7f54c5f70675b046fe /ovsdb/transaction.h
parent828cd4c7cd666b93f72d57e5932b5becf0809619 (diff)
downloadopenvswitch-5f8e32136eacbc91b7422b17d8208a64cfb3b8b9.tar.gz
ovsdb: Warn when result of ovsdb_txn_commit() is ignored and fix caller.
ovsdb_txn_commit() may return a ovsdb_error structure, which should be freed by the caller. The only remaining caller that discards the result is in ovsdb_file_open__(), which this fixes. Suggested-by: Ben Pfaff <blp@nicira.com>
Diffstat (limited to 'ovsdb/transaction.h')
-rw-r--r--ovsdb/transaction.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/ovsdb/transaction.h b/ovsdb/transaction.h
index 414b358b5..1d03ebdaf 100644
--- a/ovsdb/transaction.h
+++ b/ovsdb/transaction.h
@@ -26,7 +26,8 @@ struct uuid;
struct ovsdb_txn *ovsdb_txn_create(struct ovsdb *);
void ovsdb_txn_abort(struct ovsdb_txn *);
-struct ovsdb_error *ovsdb_txn_commit(struct ovsdb_txn *, bool durable);
+struct ovsdb_error *ovsdb_txn_commit(struct ovsdb_txn *, bool durable)
+ WARN_UNUSED_RESULT;
struct ovsdb_row *ovsdb_txn_row_modify(struct ovsdb_txn *,
const struct ovsdb_row *);