CID 717443: Dereference after null check (FORWARD_NULL)
At (14): Passing null pointer "detailbl" to function
"ceph::buffer::list::append(std::string const &)", which dereferences it.
Signed-off-by: Joao Eduardo Luis <joao.luis@inktank.com>
while (!detail.empty()) {
if (f)
f->dump_string("item", detail.front().second);
- detailbl->append(detail.front().second);
- detailbl->append('\n');
+ if (detailbl != NULL) {
+ detailbl->append(detail.front().second);
+ detailbl->append('\n');
+ }
detail.pop_front();
}
if (f)