diff --git a/src/k2/connector/yb/pggate/catalog/sql_catalog_entity.cc b/src/k2/connector/yb/pggate/catalog/sql_catalog_entity.cc index 146a24e8..09be2caf 100644 --- a/src/k2/connector/yb/pggate/catalog/sql_catalog_entity.cc +++ b/src/k2/connector/yb/pggate/catalog/sql_catalog_entity.cc @@ -41,14 +41,14 @@ ClusterInfo::~ClusterInfo() { SessionTransactionContext::SessionTransactionContext(std::shared_ptr txn) { txn_ = txn; - finished = false; + finished_ = false; } SessionTransactionContext::~SessionTransactionContext() { - if (!finished) { + if (!finished_) { // abort the transaction if it has been committed or aborted EndTransaction(false); - finished = true; + finished_ = true; } } diff --git a/src/k2/connector/yb/pggate/catalog/sql_catalog_entity.h b/src/k2/connector/yb/pggate/catalog/sql_catalog_entity.h index a32904d3..d0e4316e 100644 --- a/src/k2/connector/yb/pggate/catalog/sql_catalog_entity.h +++ b/src/k2/connector/yb/pggate/catalog/sql_catalog_entity.h @@ -157,19 +157,19 @@ class SessionTransactionContext { void Commit() { EndTransaction(true); - finished = true; + finished_ = true; } void Abort() { EndTransaction(false); - finished = true; + finished_ = true; } private: void EndTransaction(bool should_commit); std::shared_ptr txn_; - bool finished; + bool finished_; }; // mapping to the status code defined in yb's status.h (some are not applicable and thus, not included here)