Skip to content

Commit

Permalink
rgw/admin: 'bucket stats' displays non-empty mtime
Browse files Browse the repository at this point in the history
Fixes: https://tracker.ceph.com/issues/58932

Signed-off-by: Casey Bodley <cbodley@redhat.com>
  • Loading branch information
cbodley committed Mar 7, 2023
1 parent 808b451 commit 3249c2c
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/rgw/driver/rados/rgw_bucket.cc
Original file line number Diff line number Diff line change
Expand Up @@ -870,7 +870,6 @@ static int bucket_stats(rgw::sal::Driver* driver,
std::unique_ptr<rgw::sal::Bucket> bucket;
map<RGWObjCategory, RGWStorageStats> stats;

real_time mtime;
int ret = driver->get_bucket(dpp, nullptr, tenant_name, bucket_name, &bucket, null_yield);
if (ret < 0) {
return ret;
Expand All @@ -891,7 +890,7 @@ static int bucket_stats(rgw::sal::Driver* driver,
return ret;
}

utime_t ut(mtime);
utime_t ut(bucket->get_modification_time());
utime_t ctime_ut(bucket->get_creation_time());

formatter->open_object_section("stats");
Expand Down

0 comments on commit 3249c2c

Please sign in to comment.