]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
common/mds/osd: Explicitly delete if no copy, and remove incorrect comment 19465/head
authorShinobu Kinjo <shinobu@redhat.com>
Wed, 13 Dec 2017 05:48:09 +0000 (14:48 +0900)
committerShinobu Kinjo <shinobu@redhat.com>
Thu, 14 Dec 2017 10:23:12 +0000 (19:23 +0900)
Signed-off-by: Shinobu Kinjo <shinobu@redhat.com>
src/include/elist.h
src/include/xlist.h
src/mds/Capability.h
src/osd/OSDMap.h
src/osdc/Objecter.h

index 1bf3df8c6c8758f526b7ee847b0d62316ace69de..6719b9c92d84053196b77780f8895ff5d0075fb4 100644 (file)
@@ -39,9 +39,8 @@ public:
       assert(!is_on_list());
     }
 
-    // no copying!
-    item(const item& other);
-    const item& operator= (const item& right);
+    item(const item& other) = delete;
+    const item& operator= (const item& right) = delete;
 
     
     bool empty() const { return _prev == this; }
index 3e39333e511d4245d785c5ce7cf5d34531829486..5e4995af8300bdbd7068d5fa404b4eeef6a11720 100644 (file)
@@ -33,9 +33,8 @@ public:
       //remove_myself();
     }
 
-    // no copying!
-    item(const item& other);
-    const item& operator= (const item& right);
+    item(const item& other) = delete;
+    const item& operator= (const item& right) = delete;
 
     
     xlist* get_list() { return _list; }
index e3ada8411c43e798ad9f09745ed0a8f805ce8b14..3543efee849fbc752070e49c62b7082752e87688 100644 (file)
@@ -127,9 +127,9 @@ public:
     mseq(0),
     suppress(0), state(0) {
   }
-  Capability(const Capability& other);  // no copying
+  Capability(const Capability& other) = delete;
 
-  const Capability& operator=(const Capability& other);  // no copying
+  const Capability& operator=(const Capability& other) = delete;
 
   int pending() { return _pending; }
   int issued() { return _issued; }
index d817a632a017ba5bddf3cc0c4c6a51a7a766b82f..fd1f381d90cf8570c2a49c121833fad2ae9b3046 100644 (file)
@@ -587,7 +587,6 @@ private:
     memset(&fsid, 0, sizeof(fsid));
   }
 
-  // no copying
 private:
   OSDMap(const OSDMap& other) = default;
   OSDMap& operator=(const OSDMap& other) = default;
index de225dc865b4d1ae2149eb40311eec755de16801..701e642ecc8c01dec69ab3a4b3abce5e4b293774 100644 (file)
@@ -1754,9 +1754,8 @@ public:
                 ping_tid(0),
                 map_dne_bound(0) {}
 
-    // no copy!
-    const LingerOp &operator=(const LingerOp& r);
-    LingerOp(const LingerOp& o);
+    const LingerOp &operator=(const LingerOp& r) = delete;
+    LingerOp(const LingerOp& o) = delete;
 
     uint64_t get_cookie() {
       return reinterpret_cast<uint64_t>(this);