]> git.mxchange.org Git - simgear.git/blobdiff - simgear/structure/SGReferenced.hxx
Fix #1783: repeated error message on console
[simgear.git] / simgear / structure / SGReferenced.hxx
index 69788b3f13aa42f4aa70565fcd23590d05db2672..67e4fb1ed18ba36b7d42d206dfd9155047d0a0ee 100644 (file)
@@ -42,11 +42,11 @@ public:
   { return *this; }
 
   static unsigned get(const SGReferenced* ref)
-  { if (ref) return ++(ref->_refcount); else return ~0u; }
+  { if (ref) return ++(ref->_refcount); else return 0; }
   static unsigned put(const SGReferenced* ref)
-  { if (ref) return --(ref->_refcount); else return ~0u; }
+  { if (ref) return --(ref->_refcount); else return 0; }
   static unsigned count(const SGReferenced* ref)
-  { if (ref) return ref->_refcount; else return ~0u; }
+  { if (ref) return ref->_refcount; else return 0; }
   static bool shared(const SGReferenced* ref)
   { if (ref) return 1u < ref->_refcount; else return false; }