]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
osd: fix PG dtor compile error
authorSage Weil <sage@inktank.com>
Fri, 6 Jul 2012 04:26:27 +0000 (21:26 -0700)
committerSage Weil <sage@inktank.com>
Fri, 6 Jul 2012 04:26:27 +0000 (21:26 -0700)
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 <sage@inktank.com>
src/osd/PG.cc
src/osd/PG.h

index 1d22a11c366508864269e25a11abfd4271b8a07c..d048e20da7dfde7e1c21a6e5041860c11811bc95 100644 (file)
@@ -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)
 {
index ab7b90f892e6a3fed40670e2caf8401e7a72357d..f6076aa6fa6f9a306b85dd2b8ed803a85f70c929 100644 (file)
@@ -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