Skip to content

Commit 0dd5000

Browse files
committed
testing: explicitly 0-initialize CassMetrics struct
Without this, valgrind complains about access to uninitialized memory.
1 parent e5e0ec5 commit 0dd5000

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

tests/src/integration/objects/session.hpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ class Session : public Object<CassSession, cass_session_free> {
111111
* @return Driver metrics
112112
*/
113113
CassMetrics metrics() const {
114-
CassMetrics metrics;
114+
CassMetrics metrics = {};
115115
cass_session_get_metrics(get(), &metrics);
116116
return metrics;
117117
}

0 commit comments

Comments
 (0)