summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYehuda Sadeh <yehuda@inktank.com>2013-08-12 10:05:44 -0700
committerYehuda Sadeh <yehuda@inktank.com>2013-08-12 14:31:05 -0700
commit6a37a62b6f794026b82b88630519ec2cde4f20d6 (patch)
tree8934ed29321771fae5a619269da2b4ea9272f4c3
parent586c68f544c95f9e379df7e4d2705a3090baca49 (diff)
downloadceph-6a37a62b6f794026b82b88630519ec2cde4f20d6.tar.gz
rgw: fix multi delete
Fixes: #5931 Backport: bobtail, cuttlefish Fix a bad check, where we compare the wrong field. Instead of comparing the ret code to 0, we compare the string value to 0 which generates implicit casting, hence the crash. Signed-off-by: Yehuda Sadeh <yehuda@inktank.com> Reviewed-by: Josh Durgin <josh.durgin@inktank.com> (cherry picked from commit f9f1c48ad799da2b4be0077bf9d61ae116da33d7) Conflicts: src/rgw/rgw_rest_s3.cc
-rw-r--r--src/rgw/rgw_rest_s3.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/rgw/rgw_rest_s3.cc b/src/rgw/rgw_rest_s3.cc
index 44dccbb0a6a..2c09f6f712b 100644
--- a/src/rgw/rgw_rest_s3.cc
+++ b/src/rgw/rgw_rest_s3.cc
@@ -1420,7 +1420,7 @@ void RGWDeleteMultiObj_ObjStore_S3::send_partial_response(pair<string,int>& resu
s->formatter->open_object_section("Deleted");
s->formatter->dump_string("Key", result.first);
s->formatter->close_section();
- } else if (result.first < 0) {
+ } else if (result.second < 0) {
struct rgw_html_errors r;
int err_no;