]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
*** empty log message ***
authorsage <sage@29311d96-e01e-0410-9327-a35deaab8ce9>
Tue, 14 Feb 2006 19:07:42 +0000 (19:07 +0000)
committersage <sage@29311d96-e01e-0410-9327-a35deaab8ce9>
Tue, 14 Feb 2006 19:07:42 +0000 (19:07 +0000)
git-svn-id: https://ceph.svn.sf.net/svnroot/ceph@630 29311d96-e01e-0410-9327-a35deaab8ce9

ceph/common/Mutex.h
ceph/osd/OSD.h

index f2a7460980e4cc88d5258b8ac815210749179140..d2e18e8a2d839262eaf54c009fe23592fa095e81 100755 (executable)
@@ -71,9 +71,10 @@ class Mutex
   }
 
   int Lock()  { 
-       if (tag) cout << this << " " << pthread_self() << endl; 
+       int t = tag;
+       if (t) cout << this << " " << pthread_self() << endl; 
        int r = pthread_mutex_lock(&M);
-       if (tag) cout << "lock = " << r << endl;
+       if (t) cout << "lock = " << r << endl;
        return r;
   }
 
@@ -91,9 +92,10 @@ class Mutex
 
   int Unlock() 
   { 
-       if (tag) cout << this << " " << pthread_self() << endl;
+       int t = tag;
+       if (t) cout << this << " " << pthread_self() << endl;
        int r = pthread_mutex_unlock(&M);
-       if (tag) cout << "lock = " << r << endl;
+       if (t) cout << "lock = " << r << endl;
        return r;
   }
 
index a4f7b43fe96aa9a61bd7b6f75bd3cceda854e8f7..31f7ad78c9084fc3b14abf96b6a4a3ae7c3c93eb 100644 (file)
@@ -62,7 +62,7 @@ class OSDReplicaOp {
        sent_ack(false), sent_safe(false),
        new_version(nv), old_version(ov)
        { }
-  bool can_send_ack() { return !sent_ack &&   //!cancel && 
+  bool can_send_ack() { return !sent_ack && !sent_safe &&   //!cancel && 
                                                  waitfor_ack.empty(); }
   bool can_send_safe() { return !sent_safe &&    //!cancel && 
                                                   waitfor_ack.empty() && waitfor_safe.empty(); }