}
if (values.size() && values.begin()->first == key) {
- cout << " (length " << values.begin()->second.length() << ") : ";
if (!outfile.empty()) {
cerr << "Writing to " << outfile << std::endl;
dump_data(outfile, values.begin()->second);
} else {
+ cout << "value (" << values.begin()->second.length() << " bytes) :\n";
values.begin()->second.hexdump(cout);
cout << std::endl;
}
// dump key in hex if it contains nonprintable characters
if (std::count_if(it->first.begin(), it->first.end(),
(int (*)(int))isprint) < (int)it->first.length()) {
- cout << "key: (" << it->first.length() << " bytes):\n";
+ cout << "key (" << it->first.length() << " bytes):\n";
bufferlist keybl;
keybl.append(it->first);
keybl.hexdump(cout);
cout << it->first;
}
cout << std::endl;
- cout << "value: (" << it->second.length() << " bytes) :\n";
+ cout << "value (" << it->second.length() << " bytes) :\n";
it->second.hexdump(cout);
cout << std::endl;
}