Skip to content

Commit

Permalink
rgw: for the create_bucket api, if the input creation_time is zero, w…
Browse files Browse the repository at this point in the history
…e should set it to 'now"

Signed-off-by: weiqiaomiao <wei.qiaomiao@zte.com.cn>
  • Loading branch information
weiqiaomiao committed Jul 4, 2016
1 parent 3d5fa5e commit ed781e7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/rgw/rgw_rados.cc
Original file line number Diff line number Diff line change
Expand Up @@ -5079,7 +5079,7 @@ int RGWRados::create_bucket(RGWUserInfo& owner, rgw_bucket& bucket,
info.bucket_index_shard_hash_type = RGWBucketInfo::MOD;
info.requester_pays = false;
if (real_clock::is_zero(creation_time)) {
creation_time = ceph::real_clock::now(cct);
info.creation_time = ceph::real_clock::now(cct);
} else {
info.creation_time = creation_time;
}
Expand Down

0 comments on commit ed781e7

Please sign in to comment.