journaler: uninit var in ctor

CID 717348: Uninitialized scalar field (UNINIT_CTOR)
At (14): Non-static class member field "layout.fl_pg_pool" is not initialized in this constructor nor in any functions that it calls.

Signed-off-by: Sage Weil <sage@inktank.com>
This commit is contained in:
Sage Weil 2012-09-28 07:35:39 -07:00
parent 50460f90f5
commit 7b90139f4e

View File

@ -74,7 +74,9 @@ public:
Header(const char *m="") :
trimmed_pos(0), expire_pos(0), unused_field(0), write_pos(0),
magic(m) { }
magic(m) {
memset(&layout, 0, sizeof(layout));
}
void encode(bufferlist &bl) const {
__u8 struct_v = 1;