From: Danny Al-Gaaf Date: Mon, 11 Mar 2013 14:47:14 +0000 (+0100) Subject: rgw/rgw_rados.h: use static_cast instead of C-Style cast X-Git-Tag: v0.60~106^2~10 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=9f34cf582293447dffaf2b77967aabab1ca0f93f;p=ceph.git rgw/rgw_rados.h: use static_cast instead of C-Style cast Signed-off-by: Danny Al-Gaaf --- diff --git a/src/rgw/rgw_rados.h b/src/rgw/rgw_rados.h index 3ae13c8524c8..ed6f35eca72c 100644 --- a/src/rgw/rgw_rados.h +++ b/src/rgw/rgw_rados.h @@ -677,20 +677,20 @@ public: return rctx; } void destroy_context(void *ctx) { - delete (RGWRadosCtx *)ctx; + delete static_cast(ctx); } void set_atomic(void *ctx, rgw_obj& obj) { - RGWRadosCtx *rctx = (RGWRadosCtx *)ctx; + RGWRadosCtx *rctx = static_cast(ctx); rctx->set_atomic(obj); } void set_prefetch_data(void *ctx, rgw_obj& obj) { - RGWRadosCtx *rctx = (RGWRadosCtx *)ctx; + RGWRadosCtx *rctx = static_cast(ctx); rctx->set_prefetch_data(obj); } // to notify upper layer that we need to do some operation on an object, and it's up to // the upper layer to schedule this operation.. e.g., log intent in intent log void set_intent_cb(void *ctx, int (*cb)(RGWRados *store, void *user_ctx, rgw_obj& obj, RGWIntentEvent intent)) { - RGWRadosCtx *rctx = (RGWRadosCtx *)ctx; + RGWRadosCtx *rctx = static_cast(ctx); rctx->set_intent_cb(cb); }