summaryrefslogtreecommitdiff
path: root/archivers/zipios++/files/patch-simplesmartptr.h
diff options
context:
space:
mode:
authorYing-Chieh Liao <ijliao@FreeBSD.org>2002-09-07 14:19:02 +0000
committerYing-Chieh Liao <ijliao@FreeBSD.org>2002-09-07 14:19:02 +0000
commit4c15fe3e8c119caa8cd5643a731809623d9b78eb (patch)
treeb97f61bacceb252520bcfa70c253c176c3eeca27 /archivers/zipios++/files/patch-simplesmartptr.h
parent1. fix build with gcc 3.2 (diff)
forgot to include all the patches last commit
Notes
Notes: svn path=/head/; revision=65783
Diffstat (limited to 'archivers/zipios++/files/patch-simplesmartptr.h')
-rw-r--r--archivers/zipios++/files/patch-simplesmartptr.h37
1 files changed, 37 insertions, 0 deletions
diff --git a/archivers/zipios++/files/patch-simplesmartptr.h b/archivers/zipios++/files/patch-simplesmartptr.h
new file mode 100644
index 000000000000..fd50e16159cc
--- /dev/null
+++ b/archivers/zipios++/files/patch-simplesmartptr.h
@@ -0,0 +1,37 @@
+--- zipios++/simplesmartptr.h.orig Sun Jul 15 15:42:34 2001
++++ zipios++/simplesmartptr.h Sat Sep 7 10:46:20 2002
+@@ -99,13 +99,14 @@
+ class ReferenceCount {
+ /** SimpleSmartPointer needs to be a friend to invoke the private
+ ref() and unref() methods. */
+- friend SimpleSmartPointer< Type > ;
+- friend SimpleSmartPointer< const Type > ;
++ friend class SimpleSmartPointer< Type > ;
++ friend class SimpleSmartPointer< const Type > ;
+ /** Type also needs to be a friend to invoke the private ref() and
+ unref() methods, in case Type doesn't want to inherit
+ ReferenceCount and thus needs to invoke ref() and unref()
+ through forwarding member functions. */
+- friend Type ;
++ /* Note: template parameters cannot be friends */
++ //friend Type ;
+ public:
+ /** Constructor intializes count to zero. */
+ ReferenceCount() : _ref_count( 0 ) {}
+@@ -117,7 +118,6 @@
+ /** The assignment operator doesn't copy the reference count, it
+ leaves it unchanged. */
+ const ReferenceCount &operator= ( const ReferenceCount &src ) {}
+-private:
+
+ /** Increases the reference count. */
+ void ref() const { ++_ref_count ; }
+@@ -127,6 +127,8 @@
+
+ /** Returns the reference count - For debugging purposes. */
+ unsigned int getReferenceCount() const { return _ref_count; }
++
++private:
+
+ /** Holds the actual reference count */
+ mutable unsigned short _ref_count ;