]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
osd: initialize role of pg more properly
authorxie xingguo <xie.xingguo@zte.com.cn>
Fri, 15 Apr 2016 13:00:10 +0000 (21:00 +0800)
committerxie xingguo <xie.xingguo@zte.com.cn>
Sat, 23 Apr 2016 01:11:25 +0000 (09:11 +0800)
"O" means pg is primary, we can't declare that at construction.

Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
src/osd/PG.cc

index 33740739a49e2e9b1c9541a20a63056dc704b0c5..4ab0c032cca350f889a1530c0e1744691a86e286 100644 (file)
@@ -214,7 +214,7 @@ PG::PG(OSDService *o, OSDMapRef curmap,
   snap_trim_queued(false),
   scrub_queued(false),
   recovery_ops_active(0),
-  role(0),
+  role(-1),
   state(0),
   send_notify(false),
   pg_whoami(osd->whoami, p.shard),