diff options
author | Sage Weil <sage@inktank.com> | 2013-07-21 21:42:07 -0700 |
---|---|---|
committer | Sage Weil <sage@inktank.com> | 2013-07-21 21:42:07 -0700 |
commit | da2cb0901d6cdb5106deb8294b312e83dffd83db (patch) | |
tree | 197e7490049eea1a9c8b2e48039854249cbd995b | |
parent | c456390158750355884d522133362ac05213471a (diff) | |
parent | 617b3f750e83b21d511798e85193d95097918e59 (diff) | |
download | ceph-da2cb0901d6cdb5106deb8294b312e83dffd83db.tar.gz |
Merge pull request #453 from dalgaaf/wip-da-SCA-cppcheck-7
Fix SCA and CID issues
Reviewed-by: Sage Weil <sage@inktank.com>
-rw-r--r-- | src/cls/replica_log/cls_replica_log_types.h | 2 | ||||
-rw-r--r-- | src/mon/PGMonitor.cc | 2 | ||||
-rw-r--r-- | src/rgw/rgw_bucket.cc | 8 | ||||
-rw-r--r-- | src/rgw/rgw_metadata.cc | 12 | ||||
-rw-r--r-- | src/rgw/rgw_op.h | 52 | ||||
-rw-r--r-- | src/rgw/rgw_rest_bucket.cc | 14 | ||||
-rw-r--r-- | src/rgw/rgw_rest_config.h | 2 | ||||
-rw-r--r-- | src/rgw/rgw_rest_log.h | 30 | ||||
-rw-r--r-- | src/rgw/rgw_rest_metadata.cc | 4 | ||||
-rw-r--r-- | src/rgw/rgw_rest_metadata.h | 12 | ||||
-rw-r--r-- | src/rgw/rgw_rest_opstate.h | 8 | ||||
-rw-r--r-- | src/rgw/rgw_rest_replica_log.h | 18 | ||||
-rw-r--r-- | src/rgw/rgw_rest_usage.cc | 4 | ||||
-rw-r--r-- | src/rgw/rgw_rest_user.cc | 22 | ||||
-rw-r--r-- | src/rgw/rgw_swift_auth.h | 2 | ||||
-rw-r--r-- | src/test/cls_version/test_cls_version.cc | 2 |
16 files changed, 97 insertions, 97 deletions
diff --git a/src/cls/replica_log/cls_replica_log_types.h b/src/cls/replica_log/cls_replica_log_types.h index acd55dde533..6056f8e4468 100644 --- a/src/cls/replica_log/cls_replica_log_types.h +++ b/src/cls/replica_log/cls_replica_log_types.h @@ -61,7 +61,7 @@ struct cls_replica_log_progress_marker { position_time(time) {} cls_replica_log_progress_marker(const string& entity, const string& marker, const utime_t& time, - const std::list<cls_replica_log_item_marker> b) : + const std::list<cls_replica_log_item_marker>& b) : entity_id(entity), position_marker(marker), position_time(time), items(b) {} diff --git a/src/mon/PGMonitor.cc b/src/mon/PGMonitor.cc index 1f11d5486cf..648a8fe2384 100644 --- a/src/mon/PGMonitor.cc +++ b/src/mon/PGMonitor.cc @@ -1794,8 +1794,8 @@ void PGMonitor::get_health(list<pair<health_status_t,string> >& summary, ss << sum << " requests are blocked > " << g_conf->mon_osd_max_op_age << " sec"; summary.push_back(make_pair(HEALTH_WARN, ss.str())); - unsigned num_slow_osds = 0; if (detail) { + unsigned num_slow_osds = 0; // do per-osd warnings for (hash_map<int32_t,osd_stat_t>::const_iterator p = pg_map.osd_stat.begin(); p != pg_map.osd_stat.end(); diff --git a/src/rgw/rgw_bucket.cc b/src/rgw/rgw_bucket.cc index 400ee8dd2a4..d4cfdc88e64 100644 --- a/src/rgw/rgw_bucket.cc +++ b/src/rgw/rgw_bucket.cc @@ -1463,7 +1463,7 @@ public: } int list_keys_next(void *handle, int max, list<string>& keys, bool *truncated) { - list_keys_info *info = (list_keys_info *)handle; + list_keys_info *info = static_cast<list_keys_info *>(handle); string no_filter; @@ -1497,7 +1497,7 @@ public: } void list_keys_complete(void *handle) { - list_keys_info *info = (list_keys_info *)handle; + list_keys_info *info = static_cast<list_keys_info *>(handle); delete info; } }; @@ -1610,7 +1610,7 @@ public: } int list_keys_next(void *handle, int max, list<string>& keys, bool *truncated) { - list_keys_info *info = (list_keys_info *)handle; + list_keys_info *info = static_cast<list_keys_info *>(handle); string no_filter; @@ -1645,7 +1645,7 @@ public: } void list_keys_complete(void *handle) { - list_keys_info *info = (list_keys_info *)handle; + list_keys_info *info = static_cast<list_keys_info *>(handle); delete info; } diff --git a/src/rgw/rgw_metadata.cc b/src/rgw/rgw_metadata.cc index 7be73e6ca0c..ac8c703f5e0 100644 --- a/src/rgw/rgw_metadata.cc +++ b/src/rgw/rgw_metadata.cc @@ -104,7 +104,7 @@ void RGWMetadataLog::init_list_entries(int shard_id, utime_t& from_time, utime_t } void RGWMetadataLog::complete_list_entries(void *handle) { - LogListCtx *ctx = (LogListCtx *)handle; + LogListCtx *ctx = static_cast<LogListCtx *>(handle); delete ctx; } @@ -112,7 +112,7 @@ int RGWMetadataLog::list_entries(void *handle, int max_entries, list<cls_log_entry>& entries, bool *truncated) { - LogListCtx *ctx = (LogListCtx *)handle; + LogListCtx *ctx = static_cast<LogListCtx *>(handle); if (!max_entries) { *truncated = false; @@ -210,7 +210,7 @@ public: return 0; } virtual int list_keys_next(void *handle, int max, list<string>& keys, bool *truncated) { - iter_data *data = (iter_data *)handle; + iter_data *data = static_cast<iter_data *>(handle); for (int i = 0; i < max && data->iter != data->sections.end(); ++i, ++(data->iter)) { keys.push_back(*data->iter); } @@ -220,7 +220,7 @@ public: return 0; } virtual void list_keys_complete(void *handle) { - iter_data *data = (iter_data *)handle; + iter_data *data = static_cast<iter_data *>(handle); delete data; } @@ -451,7 +451,7 @@ int RGWMetadataManager::list_keys_init(string& section, void **handle) int RGWMetadataManager::list_keys_next(void *handle, int max, list<string>& keys, bool *truncated) { - list_keys_handle *h = (list_keys_handle *)handle; + list_keys_handle *h = static_cast<list_keys_handle *>(handle); RGWMetadataHandler *handler = h->handler; @@ -461,7 +461,7 @@ int RGWMetadataManager::list_keys_next(void *handle, int max, list<string>& keys void RGWMetadataManager::list_keys_complete(void *handle) { - list_keys_handle *h = (list_keys_handle *)handle; + list_keys_handle *h = static_cast<list_keys_handle *>(handle); RGWMetadataHandler *handler = h->handler; diff --git a/src/rgw/rgw_op.h b/src/rgw/rgw_op.h index 7bca53b5e43..e107b90a155 100644 --- a/src/rgw/rgw_op.h +++ b/src/rgw/rgw_op.h @@ -50,7 +50,7 @@ public: virtual void execute() = 0; virtual void send_response() {} virtual void complete() { send_response(); } - virtual const char *name() = 0; + virtual const string name() = 0; virtual uint32_t op_mask() { return 0; } }; @@ -117,7 +117,7 @@ public: virtual int get_params() = 0; virtual int send_response_data(bufferlist& bl, off_t ofs, off_t len) = 0; - virtual const char *name() { return "get_obj"; } + virtual const string name() { return "get_obj"; } virtual uint32_t op_mask() { return RGW_OP_TYPE_READ; } }; @@ -147,7 +147,7 @@ public: virtual bool should_get_stats() { return false; } - virtual const char *name() { return "list_buckets"; } + virtual const string name() { return "list_buckets"; } virtual uint32_t op_mask() { return RGW_OP_TYPE_READ; } }; @@ -172,7 +172,7 @@ public: void execute(); virtual void send_response() = 0; - virtual const char *name() { return "stat_account"; } + virtual const string name() { return "stat_account"; } virtual uint32_t op_mask() { return RGW_OP_TYPE_READ; } }; @@ -204,7 +204,7 @@ public: virtual int get_params() = 0; virtual void send_response() = 0; - virtual const char *name() { return "list_bucket"; } + virtual const string name() { return "list_bucket"; } virtual uint32_t op_mask() { return RGW_OP_TYPE_READ; } }; @@ -215,7 +215,7 @@ public: void execute() {} virtual void send_response() = 0; - virtual const char *name() { return "get_bucket_logging"; } + virtual const string name() { return "get_bucket_logging"; } virtual uint32_t op_mask() { return RGW_OP_TYPE_READ; } }; @@ -232,7 +232,7 @@ public: void execute(); virtual void send_response() = 0; - virtual const char *name() { return "stat_bucket"; } + virtual const string name() { return "stat_bucket"; } virtual uint32_t op_mask() { return RGW_OP_TYPE_READ; } }; @@ -258,7 +258,7 @@ public: } virtual int get_params() { return 0; } virtual void send_response() = 0; - virtual const char *name() { return "create_bucket"; } + virtual const string name() { return "create_bucket"; } virtual uint32_t op_mask() { return RGW_OP_TYPE_WRITE; } }; @@ -275,7 +275,7 @@ public: void execute(); virtual void send_response() = 0; - virtual const char *name() { return "delete_bucket"; } + virtual const string name() { return "delete_bucket"; } virtual uint32_t op_mask() { return RGW_OP_TYPE_DELETE; } }; @@ -319,7 +319,7 @@ public: virtual int get_params() = 0; virtual int get_data(bufferlist& bl) = 0; virtual void send_response() = 0; - virtual const char *name() { return "put_obj"; } + virtual const string name() { return "put_obj"; } virtual uint32_t op_mask() { return RGW_OP_TYPE_WRITE; } }; @@ -361,7 +361,7 @@ public: virtual int get_params() = 0; virtual int get_data(bufferlist& bl) = 0; virtual void send_response() = 0; - virtual const char *name() { return "post_obj"; } + virtual const string name() { return "post_obj"; } virtual uint32_t op_mask() { return RGW_OP_TYPE_WRITE; } }; @@ -389,7 +389,7 @@ public: virtual int get_params() = 0; virtual void send_response() = 0; - virtual const char *name() { return "put_obj_metadata"; } + virtual const string name() { return "put_obj_metadata"; } virtual uint32_t op_mask() { return RGW_OP_TYPE_WRITE; } }; @@ -404,7 +404,7 @@ public: void execute(); virtual void send_response() = 0; - virtual const char *name() { return "delete_obj"; } + virtual const string name() { return "delete_obj"; } virtual uint32_t op_mask() { return RGW_OP_TYPE_DELETE; } }; @@ -472,7 +472,7 @@ public: virtual int init_dest_policy() { return 0; } virtual int get_params() = 0; virtual void send_response() = 0; - virtual const char *name() { return "copy_obj"; } + virtual const string name() { return "copy_obj"; } virtual uint32_t op_mask() { return RGW_OP_TYPE_WRITE; } }; @@ -488,7 +488,7 @@ public: void execute(); virtual void send_response() = 0; - virtual const char *name() { return "get_acls"; } + virtual const string name() { return "get_acls"; } virtual uint32_t op_mask() { return RGW_OP_TYPE_READ; } }; @@ -514,7 +514,7 @@ public: virtual int get_policy_from_state(RGWRados *store, struct req_state *s, stringstream& ss) { return 0; } virtual int get_params() = 0; virtual void send_response() = 0; - virtual const char *name() { return "put_acls"; } + virtual const string name() { return "put_acls"; } virtual uint32_t op_mask() { return RGW_OP_TYPE_WRITE; } }; @@ -530,7 +530,7 @@ public: void execute(); virtual void send_response() = 0; - virtual const char *name() { return "get_cors"; } + virtual const string name() { return "get_cors"; } virtual uint32_t op_mask() { return RGW_OP_TYPE_READ; } }; @@ -555,7 +555,7 @@ public: virtual int get_params() = 0; virtual void send_response() = 0; - virtual const char *name() { return "put_cors"; } + virtual const string name() { return "put_cors"; } virtual uint32_t op_mask() { return RGW_OP_TYPE_WRITE; } }; @@ -570,7 +570,7 @@ public: void execute(); virtual void send_response() = 0; - virtual const char *name() { return "delete_cors"; } + virtual const string name() { return "delete_cors"; } virtual uint32_t op_mask() { return RGW_OP_TYPE_WRITE; } }; @@ -590,7 +590,7 @@ public: void execute(); void get_response_params(string& allowed_hdrs, string& exp_hdrs, unsigned *max_age); virtual void send_response() = 0; - virtual const char *name() { return "options_cors"; } + virtual const string name() { return "options_cors"; } virtual uint32_t op_mask() { return RGW_OP_TYPE_READ; } }; @@ -614,7 +614,7 @@ public: virtual int get_params() = 0; virtual void send_response() = 0; - virtual const char *name() { return "init_multipart"; } + virtual const string name() { return "init_multipart"; } virtual uint32_t op_mask() { return RGW_OP_TYPE_WRITE; } }; @@ -643,7 +643,7 @@ public: virtual int get_params() = 0; virtual void send_response() = 0; - virtual const char *name() { return "complete_multipart"; } + virtual const string name() { return "complete_multipart"; } virtual uint32_t op_mask() { return RGW_OP_TYPE_WRITE; } }; @@ -658,7 +658,7 @@ public: void execute(); virtual void send_response() = 0; - virtual const char *name() { return "abort_multipart"; } + virtual const string name() { return "abort_multipart"; } virtual uint32_t op_mask() { return RGW_OP_TYPE_DELETE; } }; @@ -687,7 +687,7 @@ public: virtual int get_params() = 0; virtual void send_response() = 0; - virtual const char *name() { return "list_multipart"; } + virtual const string name() { return "list_multipart"; } virtual uint32_t op_mask() { return RGW_OP_TYPE_READ; } }; @@ -790,7 +790,7 @@ public: virtual int get_params() = 0; virtual void send_response() = 0; - virtual const char *name() { return "list_bucket_multiparts"; } + virtual const string name() { return "list_bucket_multiparts"; } virtual uint32_t op_mask() { return RGW_OP_TYPE_READ; } }; @@ -823,7 +823,7 @@ public: virtual void begin_response() = 0; virtual void send_partial_response(pair<string,int>& result) = 0; virtual void end_response() = 0; - virtual const char *name() { return "multi_object_delete"; } + virtual const string name() { return "multi_object_delete"; } virtual uint32_t op_mask() { return RGW_OP_TYPE_DELETE; } }; diff --git a/src/rgw/rgw_rest_bucket.cc b/src/rgw/rgw_rest_bucket.cc index 80b5b876916..e7068b43c49 100644 --- a/src/rgw/rgw_rest_bucket.cc +++ b/src/rgw/rgw_rest_bucket.cc @@ -17,7 +17,7 @@ public: void execute(); - virtual const char *name() { return "get_bucket_info"; } + virtual const string name() { return "get_bucket_info"; } }; void RGWOp_Bucket_Info::execute() @@ -52,7 +52,7 @@ public: void execute(); - virtual const char *name() { return "get_policy"; } + virtual const string name() { return "get_policy"; } }; void RGWOp_Get_Policy::execute() @@ -82,7 +82,7 @@ public: void execute(); - virtual const char *name() { return "check_bucket_index"; } + virtual const string name() { return "check_bucket_index"; } }; void RGWOp_Check_Bucket_Index::execute() @@ -116,7 +116,7 @@ public: void execute(); - virtual const char *name() { return "link_bucket"; } + virtual const string name() { return "link_bucket"; } }; void RGWOp_Bucket_Link::execute() @@ -146,7 +146,7 @@ public: void execute(); - virtual const char *name() { return "unlink_bucket"; } + virtual const string name() { return "unlink_bucket"; } }; void RGWOp_Bucket_Unlink::execute() @@ -176,7 +176,7 @@ public: void execute(); - virtual const char *name() { return "remove_bucket"; } + virtual const string name() { return "remove_bucket"; } }; void RGWOp_Bucket_Remove::execute() @@ -206,7 +206,7 @@ public: void execute(); - virtual const char *name() { return "remove_object"; } + virtual const string name() { return "remove_object"; } }; void RGWOp_Object_Remove::execute() diff --git a/src/rgw/rgw_rest_config.h b/src/rgw/rgw_rest_config.h index cb1712ac3d7..2e0408afb3d 100644 --- a/src/rgw/rgw_rest_config.h +++ b/src/rgw/rgw_rest_config.h @@ -25,7 +25,7 @@ public: } void execute(); virtual void send_response(); - virtual const char *name() { + virtual const string name() { return "get_region_map"; } }; diff --git a/src/rgw/rgw_rest_log.h b/src/rgw/rgw_rest_log.h index 38c6b5fb4ab..2d60e289b84 100644 --- a/src/rgw/rgw_rest_log.h +++ b/src/rgw/rgw_rest_log.h @@ -32,7 +32,7 @@ public: virtual void send_response(list<rgw_bi_log_entry>& entries, string& marker); virtual void send_response_end(); void execute(); - virtual const char *name() { + virtual const string name() { return "list_bucket_index_log"; } }; @@ -53,7 +53,7 @@ public: } virtual void send_response(); void execute(); - virtual const char *name() { + virtual const string name() { return "bucket_index_log_info"; } }; @@ -67,7 +67,7 @@ public: return caps.check_cap("bilog", RGW_CAP_WRITE); } void execute(); - virtual const char *name() { + virtual const string name() { return "trim_bucket_index_log"; } }; @@ -87,7 +87,7 @@ public: } void execute(); virtual void send_response(); - virtual const char *name() { + virtual const string name() { return "list_metadata_log"; } }; @@ -107,7 +107,7 @@ public: } void execute(); virtual void send_response(); - virtual const char *name() { + virtual const string name() { return "get_metadata_log_info"; } }; @@ -126,7 +126,7 @@ public: } void execute(); virtual void send_response(); - virtual const char *name() { + virtual const string name() { return "get_metadata_log_shard_info"; } }; @@ -140,7 +140,7 @@ public: return caps.check_cap("mdlog", RGW_CAP_WRITE); } void execute(); - virtual const char *name() { + virtual const string name() { return "lock_mdlog_object"; } }; @@ -154,7 +154,7 @@ public: return caps.check_cap("mdlog", RGW_CAP_WRITE); } void execute(); - virtual const char *name() { + virtual const string name() { return "unlock_mdlog_object"; } }; @@ -168,7 +168,7 @@ public: return caps.check_cap("mdlog", RGW_CAP_WRITE); } void execute(); - virtual const char *name() { + virtual const string name() { return "trim_metadata_log"; } }; @@ -188,7 +188,7 @@ public: } void execute(); virtual void send_response(); - virtual const char *name() { + virtual const string name() { return "list_data_changes_log"; } }; @@ -208,7 +208,7 @@ public: } void execute(); virtual void send_response(); - virtual const char *name() { + virtual const string name() { return "get_data_changes_log_info"; } }; @@ -227,7 +227,7 @@ public: } void execute(); virtual void send_response(); - virtual const char *name() { + virtual const string name() { return "get_data_changes_log_shard_info"; } }; @@ -241,7 +241,7 @@ public: return caps.check_cap("datalog", RGW_CAP_WRITE); } void execute(); - virtual const char *name() { + virtual const string name() { return "lock_datalog_object"; } }; @@ -255,7 +255,7 @@ public: return caps.check_cap("datalog", RGW_CAP_WRITE); } void execute(); - virtual const char *name() { + virtual const string name() { return "unlock_datalog_object"; } }; @@ -269,7 +269,7 @@ public: return caps.check_cap("datalog", RGW_CAP_WRITE); } void execute(); - virtual const char *name() { + virtual const string name() { return "trim_data_changes_log"; } }; diff --git a/src/rgw/rgw_rest_metadata.cc b/src/rgw/rgw_rest_metadata.cc index 69f8a5ccbc4..35ec0ab9b04 100644 --- a/src/rgw/rgw_rest_metadata.cc +++ b/src/rgw/rgw_rest_metadata.cc @@ -23,7 +23,7 @@ #define dout_subsys ceph_subsys_rgw -const char *RGWOp_Metadata_Get::name() { +const string RGWOp_Metadata_Get::name() { return "get_metadata"; } @@ -62,7 +62,7 @@ void RGWOp_Metadata_Get::execute() { http_ret = 0; } -const char *RGWOp_Metadata_List::name() { +const string RGWOp_Metadata_List::name() { return "list_metadata"; } diff --git a/src/rgw/rgw_rest_metadata.h b/src/rgw/rgw_rest_metadata.h index 85993d08d58..59d7c5f7045 100644 --- a/src/rgw/rgw_rest_metadata.h +++ b/src/rgw/rgw_rest_metadata.h @@ -23,7 +23,7 @@ public: return caps.check_cap("metadata", RGW_CAP_READ); } void execute(); - virtual const char *name(); + virtual const string name(); }; class RGWOp_Metadata_Get : public RGWRESTOp { @@ -35,7 +35,7 @@ public: return caps.check_cap("metadata", RGW_CAP_READ); } void execute(); - virtual const char *name(); + virtual const string name(); }; class RGWOp_Metadata_Put : public RGWRESTOp { @@ -48,7 +48,7 @@ public: return caps.check_cap("metadata", RGW_CAP_WRITE); } void execute(); - virtual const char *name() { return "set_metadata"; } + virtual const string name() { return "set_metadata"; } }; class RGWOp_Metadata_Delete : public RGWRESTOp { @@ -60,7 +60,7 @@ public: return caps.check_cap("metadata", RGW_CAP_WRITE); } void execute(); - virtual const char *name() { return "remove_metadata"; } + virtual const string name() { return "remove_metadata"; } }; class RGWOp_Metadata_Lock : public RGWRESTOp { @@ -72,7 +72,7 @@ public: return caps.check_cap("metadata", RGW_CAP_WRITE); } void execute(); - virtual const char *name() { + virtual const string name() { return "lock_metadata_object"; } }; @@ -86,7 +86,7 @@ public: return caps.check_cap("metadata", RGW_CAP_WRITE); } void execute(); - virtual const char *name() { + virtual const string name() { return "unlock_metadata_object"; } }; diff --git a/src/rgw/rgw_rest_opstate.h b/src/rgw/rgw_rest_opstate.h index 8f6a9675a68..de13dde6966 100644 --- a/src/rgw/rgw_rest_opstate.h +++ b/src/rgw/rgw_rest_opstate.h @@ -30,7 +30,7 @@ public: virtual void send_response(); virtual void send_response(list<cls_statelog_entry> entries); virtual void send_response_end(); - virtual const char *name() { + virtual const string name() { return "opstate_list"; } }; @@ -44,7 +44,7 @@ public: return caps.check_cap("opstate", RGW_CAP_WRITE); } void execute(); - virtual const char *name() { + virtual const string name() { return "set_opstate"; } }; @@ -58,7 +58,7 @@ public: return caps.check_cap("opstate", RGW_CAP_WRITE); } void execute(); - virtual const char *name() { + virtual const string name() { return "renew_opstate"; } }; @@ -72,7 +72,7 @@ public: return caps.check_cap("opstate", RGW_CAP_WRITE); } void execute(); - virtual const char *name() { + virtual const string name() { return "delete_opstate"; } }; diff --git a/src/rgw/rgw_rest_replica_log.h b/src/rgw/rgw_rest_replica_log.h index 91e3d614062..c879150cc07 100644 --- a/src/rgw/rgw_rest_replica_log.h +++ b/src/rgw/rgw_rest_replica_log.h @@ -32,11 +32,11 @@ public: } void execute(); virtual void send_response(); - virtual const char *name() { + virtual const string name() { string s = "replica"; s.append(obj_type); s.append("_getbounds"); - return s.c_str(); + return s; } }; @@ -52,11 +52,11 @@ public: return caps.check_cap(obj_type.c_str(), RGW_CAP_WRITE); } void execute(); - virtual const char *name() { + virtual const string name() { string s = "replica"; s.append(obj_type); s.append("_updatebounds"); - return s.c_str(); + return s; } }; @@ -72,11 +72,11 @@ public: return caps.check_cap(obj_type.c_str(), RGW_CAP_WRITE); } void execute(); - virtual const char *name() { + virtual const string name() { string s = "replica"; s.append(obj_type); s.append("_deletebound"); - return s.c_str(); + return s; } }; @@ -94,7 +94,7 @@ public: } void execute(); virtual void send_response(); - virtual const char *name() { + virtual const string name() { return "replicabilog_getbounds"; } }; @@ -108,7 +108,7 @@ public: return caps.check_cap("bilog", RGW_CAP_WRITE); } void execute(); - virtual const char *name() { + virtual const string name() { return "replicabilog_updatebounds"; } }; @@ -122,7 +122,7 @@ public: return caps.check_cap("bilog", RGW_CAP_WRITE); } void execute(); - virtual const char *name() { + virtual const string name() { return "replicabilog_deletebound"; } }; diff --git a/src/rgw/rgw_rest_usage.cc b/src/rgw/rgw_rest_usage.cc index 769e167019a..1124d2b298b 100644 --- a/src/rgw/rgw_rest_usage.cc +++ b/src/rgw/rgw_rest_usage.cc @@ -16,7 +16,7 @@ public: } void execute(); - virtual const char *name() { return "get_usage"; } + virtual const string name() { return "get_usage"; } }; void RGWOp_Usage_Get::execute() { @@ -58,7 +58,7 @@ public: } void execute(); - virtual const char *name() { return "trim_usage"; } + virtual const string name() { return "trim_usage"; } }; void RGWOp_Usage_Delete::execute() { diff --git a/src/rgw/rgw_rest_user.cc b/src/rgw/rgw_rest_user.cc index ac0d794846c..3d08e403229 100644 --- a/src/rgw/rgw_rest_user.cc +++ b/src/rgw/rgw_rest_user.cc @@ -17,7 +17,7 @@ public: void execute(); - virtual const char *name() { return "get_user_info"; } + virtual const string name() { return "get_user_info"; } }; void RGWOp_User_Info::execute() @@ -44,7 +44,7 @@ public: void execute(); - virtual const char *name() { return "create_user"; } + virtual const string name() { return "create_user"; } }; void RGWOp_User_Create::execute() @@ -138,7 +138,7 @@ public: void execute(); - virtual const char *name() { return "modify_user"; } + virtual const string name() { return "modify_user"; } }; void RGWOp_User_Modify::execute() @@ -232,7 +232,7 @@ public: void execute(); - virtual const char *name() { return "remove_user"; } + virtual const string name() { return "remove_user"; } }; void RGWOp_User_Remove::execute() @@ -265,7 +265,7 @@ public: void execute(); - virtual const char *name() { return "create_subuser"; } + virtual const string name() { return "create_subuser"; } }; void RGWOp_Subuser_Create::execute() @@ -334,7 +334,7 @@ public: void execute(); - virtual const char *name() { return "modify_subuser"; } + virtual const string name() { return "modify_subuser"; } }; void RGWOp_Subuser_Modify::execute() @@ -399,7 +399,7 @@ public: void execute(); - virtual const char *name() { return "remove_subuser"; } + virtual const string name() { return "remove_subuser"; } }; void RGWOp_Subuser_Remove::execute() @@ -438,7 +438,7 @@ public: void execute(); - virtual const char *name() { return "create_access_key"; } + virtual const string name() { return "create_access_key"; } }; void RGWOp_Key_Create::execute() @@ -500,7 +500,7 @@ public: void execute(); - virtual const char *name() { return "remove_access_key"; } + virtual const string name() { return "remove_access_key"; } }; void RGWOp_Key_Remove::execute() @@ -552,7 +552,7 @@ public: void execute(); - virtual const char *name() { return "add_user_caps"; } + virtual const string name() { return "add_user_caps"; } }; void RGWOp_Caps_Add::execute() @@ -586,7 +586,7 @@ public: void execute(); - virtual const char *name() { return "remove_user_caps"; } + virtual const string name() { return "remove_user_caps"; } }; void RGWOp_Caps_Remove::execute() diff --git a/src/rgw/rgw_swift_auth.h b/src/rgw/rgw_swift_auth.h index 8a58b476496..670a339210d 100644 --- a/src/rgw/rgw_swift_auth.h +++ b/src/rgw/rgw_swift_auth.h @@ -15,7 +15,7 @@ public: int verify_permission() { return 0; } void execute(); - virtual const char *name() { return "swift_auth_get"; } + virtual const string name() { return "swift_auth_get"; } }; class RGWHandler_SWIFT_Auth : public RGWHandler { diff --git a/src/test/cls_version/test_cls_version.cc b/src/test/cls_version/test_cls_version.cc index 6392424644a..caa0a36cd74 100644 --- a/src/test/cls_version/test_cls_version.cc +++ b/src/test/cls_version/test_cls_version.cc @@ -76,7 +76,7 @@ TEST(cls_rgw, test_version_inc_read) ASSERT_EQ(ver2.ver, ver3.ver); ASSERT_EQ(1, (long long)ver2.compare(&ver3)); - delete op; + delete rop; } |