aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/sptr.h9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/sptr.h b/src/sptr.h
index 4e581a9..4eb5a52 100644
--- a/src/sptr.h
+++ b/src/sptr.h
@@ -59,11 +59,18 @@ namespace Bu
59 * Get the number of references to this pointer. 59 * Get the number of references to this pointer.
60 *@returns (int32_t) The number of references to this pointer. 60 *@returns (int32_t) The number of references to this pointer.
61 */ 61 */
62 int32_t count() const 62 int32_t getRefCount() const
63 { 63 {
64 return *pRefCnt; 64 return *pRefCnt;
65 } 65 }
66 66
67 void clear()
68 {
69 decCount();
70 pRefCnt = NULL;
71 pData = NULL;
72 }
73
67 /** 74 /**
68 * Pointer access operator. 75 * Pointer access operator.
69 *@returns (const T *) 76 *@returns (const T *)