From: Kefu Chai Date: Sat, 6 Feb 2016 15:35:14 +0000 (+0800) Subject: osd: init HeartbeatDispatcher using OSD->cct X-Git-Tag: v10.1.0~420^2~6 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=7d08bbf59526469fbc0ff35938253ea0c74ef4a1;p=ceph.git osd: init HeartbeatDispatcher using OSD->cct its base class 'Dispatcher' is uninitialized when used here to access 'Dispatcher::cct', so we'd better use OSD::cct to initialize it instead. Signed-off-by: Kefu Chai --- diff --git a/src/osd/OSD.h b/src/osd/OSD.h index 169623a73d65..e53fc6b640ca 100644 --- a/src/osd/OSD.h +++ b/src/osd/OSD.h @@ -1565,7 +1565,7 @@ public: struct HeartbeatDispatcher : public Dispatcher { OSD *osd; - explicit HeartbeatDispatcher(OSD *o) : Dispatcher(cct), osd(o) {} + explicit HeartbeatDispatcher(OSD *o) : Dispatcher(o->cct), osd(o) {} bool ms_dispatch(Message *m) { return osd->heartbeat_dispatch(m); }