From: Sage Weil Date: Fri, 6 Jul 2012 04:26:27 +0000 (-0700) Subject: osd: fix PG dtor compile error X-Git-Tag: v0.50~109^2~1 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=3d00130bcdf18a9487d04493e524da748ef15e53;p=ceph.git osd: fix PG dtor compile error We need at least none non-pure virtual method to tell gcc where the vtable goes. The destructor wins! libosd.a(libosd_a-ReplicatedPG.o): In function `~PG': /home/sage/src/ceph/src/osd/PG.h:1367: undefined reference to `vtable for PG' libosd.a(libosd_a-ReplicatedPG.o):(.rodata._ZTI12ReplicatedPG[typeinfo for ReplicatedPG]+0x10): undefined reference to `typeinfo for PG' libosd.a(libosd_a-PG.o): In function `PG': /home/sage/src/ceph/src/osd/PG.cc:85: undefined reference to `vtable for PG' ... Signed-off-by: Sage Weil --- diff --git a/src/osd/PG.cc b/src/osd/PG.cc index 1d22a11c3665..d048e20da7df 100644 --- a/src/osd/PG.cc +++ b/src/osd/PG.cc @@ -82,7 +82,13 @@ PG::PG(OSDService *o, OSDMapRef curmap, scrub_reserved(false), scrub_reserve_failed(false), scrub_waiting_on(0), active_rep_scrub(0), - recovery_state(this) {} + recovery_state(this) +{ +} + +PG::~PG() +{ +} void PG::lock(bool no_lockdep) { diff --git a/src/osd/PG.h b/src/osd/PG.h index ab7b90f892e6..f6076aa6fa6f 100644 --- a/src/osd/PG.h +++ b/src/osd/PG.h @@ -1364,7 +1364,7 @@ public: public: PG(OSDService *o, OSDMapRef curmap, PGPool pool, pg_t p, const hobject_t& loid, const hobject_t& ioid); - virtual ~PG() {} + virtual ~PG(); private: // Prevent copying