aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorpav <pav@FreeBSD.org>2004-08-21 08:32:31 +0800
committerpav <pav@FreeBSD.org>2004-08-21 08:32:31 +0800
commitac9c27802a08454af592bd6e0745e3fc986302e7 (patch)
treefd63b9e62d8f85a9b47a04c40d91a2ec468d103c
parentdad580f351b2e0ec9758ca5c05691a8321270298 (diff)
downloadfreebsd-ports-gnome-ac9c27802a08454af592bd6e0745e3fc986302e7.tar.gz
freebsd-ports-gnome-ac9c27802a08454af592bd6e0745e3fc986302e7.tar.zst
freebsd-ports-gnome-ac9c27802a08454af592bd6e0745e3fc986302e7.zip
- Fix build with gcc 3.4
PR: ports/70664 Submitted by: Guido Falsi <mad@madpilot.net> (maintainer)
-rw-r--r--games/netpanzer/files/patch-src-Lib-ArrayUtil-LinkListDoubleTemplate.hpp11
-rw-r--r--games/netpanzer/files/patch-src-Lib-ArrayUtil-QueueTemplate.hpp66
2 files changed, 77 insertions, 0 deletions
diff --git a/games/netpanzer/files/patch-src-Lib-ArrayUtil-LinkListDoubleTemplate.hpp b/games/netpanzer/files/patch-src-Lib-ArrayUtil-LinkListDoubleTemplate.hpp
new file mode 100644
index 000000000000..0d7f5beaa8bd
--- /dev/null
+++ b/games/netpanzer/files/patch-src-Lib-ArrayUtil-LinkListDoubleTemplate.hpp
@@ -0,0 +1,11 @@
+--- src/Lib/ArrayUtil/LinkListDoubleTemplate.hpp.orig Tue Dec 2 12:40:14 2003
++++ src/Lib/ArrayUtil/LinkListDoubleTemplate.hpp Thu Aug 19 16:34:25 2004
+@@ -203,7 +203,7 @@
+ object->prev->next = before;
+ }
+
+- if(delete_ptr == front) {
++ if(object == front) {
+ front = before;
+ }
+
diff --git a/games/netpanzer/files/patch-src-Lib-ArrayUtil-QueueTemplate.hpp b/games/netpanzer/files/patch-src-Lib-ArrayUtil-QueueTemplate.hpp
new file mode 100644
index 000000000000..915ee182e555
--- /dev/null
+++ b/games/netpanzer/files/patch-src-Lib-ArrayUtil-QueueTemplate.hpp
@@ -0,0 +1,66 @@
+--- src/Lib/ArrayUtil/QueueTemplate.hpp.orig Sun Dec 21 01:48:03 2003
++++ src/Lib/ArrayUtil/QueueTemplate.hpp Thu Aug 19 16:34:31 2004
+@@ -42,8 +42,8 @@
+
+ bool enqueue(const TYPE& object )
+ {
+- add( object, (rear + 1) % size );
+- rear = (rear + 1) % size;
++ add( object, (rear + 1) % this->size );
++ rear = (rear + 1) % this->size;
+
+ if ( front == rear )
+ return( false );
+@@ -55,29 +55,29 @@
+ {
+ assert( front != rear );
+
+- front = ( front + 1 ) % size;
+- return( array[ front ] );
++ front = ( front + 1 ) % this->size;
++ return( this->array[ front ] );
+ }
+
+ void pop()
+ {
+ assert( front != rear );
+
+- front = ( front + 1 ) % size;
++ front = ( front + 1 ) % this->size;
+ }
+
+ TYPE getFirst()
+ {
+ assert( front != rear );
+
+- return( array[ (( front + 1 ) % size) ] );
++ return( this->array[ (( front + 1 ) % this->size) ] );
+ }
+
+ TYPE * getFirstPtr()
+ {
+ assert( front != rear );
+
+- return( &(array[ (( front + 1 ) % size) ]) );
++ return( &(this->array[ (( front + 1 ) % this->size) ]) );
+ }
+
+
+@@ -88,7 +88,7 @@
+
+ bool isFull () const
+ {
+- return front == (rear + 1) % size;
++ return front == (rear + 1) % this->size;
+ }
+
+ bool isReady() const
+@@ -99,7 +99,7 @@
+ unsigned long itemCount() const
+ {
+ if ( front > rear )
+- return ( (rear+1) + ( (size-1) - front ) );
++ return ( (rear+1) + ( (this->size-1) - front ) );
+ else
+ return ( rear - front );
+ }