]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
objecter: set linger op target pg when a linger is resent
authorJosh Durgin <josh.durgin@dreamhost.com>
Fri, 11 Feb 2011 21:21:05 +0000 (13:21 -0800)
committerJosh Durgin <josh.durgin@dreamhost.com>
Fri, 11 Feb 2011 21:21:52 +0000 (13:21 -0800)
send_linger always creates a new Op, but op_submit does not fill in
the target pg if an existing session is passed in, so when a linger
was resent, it had the wrong pg set.

This caused a crash in cosd with debugging turned on when running
testlibrbd twice. This occurred because the object context for the
linger in the wrong pg had no object name set.

src/osdc/Objecter.cc

index 68a425afca17aebfb1e2a6214d4ed7d31f270815..b738fe9b4873a27ff880c12639802d2113e781c3 100644 (file)
@@ -69,6 +69,9 @@ void Objecter::send_linger(LingerOp *info)
                   onack, oncommit,
                   info->pobjver);
     o->snapid = info->snap;
+
+    if (info->session)
+      recalc_op_target(o);
     op_submit(o, info->session);
     info->registering = true;
   } else {