rgw: pass POD c-string instead of string to formatter

Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
This commit is contained in:
Greg Farnum 2011-09-26 13:24:08 -07:00
parent 38c6fa5d12
commit 774aa25b8c

View File

@ -91,7 +91,7 @@ void RGWListBucket_REST_SWIFT::send_response()
if (do_objs && (marker.empty() || iter->name.compare(marker) > 0)) {
s->formatter->open_object_section("object");
s->formatter->dump_format("name", iter->name.c_str());
s->formatter->dump_format("hash", "\"%s\"", iter->etag);
s->formatter->dump_format("hash", "\"%s\"", iter->etag.c_str());
s->formatter->dump_int("bytes", iter->size);
if (iter->content_type.size())
s->formatter->dump_format("content_type", iter->content_type.c_str());