aboutsummaryrefslogtreecommitdiffstats
path: root/games
diff options
context:
space:
mode:
authorjbeich <jbeich@FreeBSD.org>2017-05-10 10:32:29 +0800
committerjbeich <jbeich@FreeBSD.org>2017-05-10 10:32:29 +0800
commitb5e1cb9ba665290666ceafc7db8001924632433b (patch)
treed0f2db234932b3b64f3aab5dbab7a1589278eae2 /games
parent4bd3d9515a8406b26e33b115902bca86f8baf7ea (diff)
downloadfreebsd-ports-gnome-b5e1cb9ba665290666ceafc7db8001924632433b.tar.gz
freebsd-ports-gnome-b5e1cb9ba665290666ceafc7db8001924632433b.tar.zst
freebsd-ports-gnome-b5e1cb9ba665290666ceafc7db8001924632433b.zip
games/openbor: oops, make sure patch(1) doesn't confuse context
Diffstat (limited to 'games')
-rw-r--r--games/openbor/Makefile3
-rw-r--r--games/openbor/files/patch-openbor.c24
-rw-r--r--games/openbor4432/files/patch-openbor.c24
3 files changed, 47 insertions, 4 deletions
diff --git a/games/openbor/Makefile b/games/openbor/Makefile
index a2535dd15737..0636dcbf120b 100644
--- a/games/openbor/Makefile
+++ b/games/openbor/Makefile
@@ -3,6 +3,9 @@
PORTNAME= openbor
# Hint: svn revision is git rev-list --count ${GH_TAGNAME}
PORTVERSION?= 4505
+.ifndef PKGNAMESUFFIX
+PORTREVISION= 1
+.endif
CATEGORIES= games
MAINTAINER= jbeich@FreeBSD.org
diff --git a/games/openbor/files/patch-openbor.c b/games/openbor/files/patch-openbor.c
index 09cbabd84270..16991f52e4d0 100644
--- a/games/openbor/files/patch-openbor.c
+++ b/games/openbor/files/patch-openbor.c
@@ -4,7 +4,12 @@ Avoid accidental rounding from abs()
--- openbor.c.orig 2017-04-22 14:20:08 UTC
+++ openbor.c
-@@ -5810,7 +5810,7 @@ s_collision_attack **collision_alloc_att
+@@ -5747,17 +5747,17 @@ s_collision_attack *collision_alloc_attack_instance(s_
+ //
+ // Allocate an empty collision attack list.
+ s_collision_attack **collision_alloc_attack_list()
+ {
+ s_collision_attack **result;
size_t alloc_size;
// Get amount of memory we'll need.
@@ -13,7 +18,17 @@ Avoid accidental rounding from abs()
// Allocate memory and get pointer.
result = malloc(alloc_size);
-@@ -5859,7 +5859,7 @@ s_collision_body **collision_alloc_body_
+
+ // Make sure the list is blank.
+ memset(result, 0, alloc_size);
+
+ // return result.
+@@ -5796,17 +5796,17 @@ s_collision_body *collision_alloc_body_instance(s_coll
+ //
+ // Allocate an empty collision attack list.
+ s_collision_body **collision_alloc_body_list()
+ {
+ s_collision_body **result;
size_t alloc_size;
// Get amount of memory we'll need.
@@ -22,6 +37,11 @@ Avoid accidental rounding from abs()
// Allocate memory and get pointer.
result = malloc(alloc_size);
+
+ // Make sure the list is blank.
+ memset(result, 0, alloc_size);
+
+ // return result.
@@ -8204,7 +8204,8 @@ size_t lcmScriptCopyBuffer(ArgList *argl
size_t lcmScriptDeleteMain(char **buf)
diff --git a/games/openbor4432/files/patch-openbor.c b/games/openbor4432/files/patch-openbor.c
index 1cab90006f74..c02af986c7f8 100644
--- a/games/openbor4432/files/patch-openbor.c
+++ b/games/openbor4432/files/patch-openbor.c
@@ -4,7 +4,12 @@ Avoid accidental rounding from abs()
--- openbor.c.orig 2016-12-22 13:02:02 UTC
+++ openbor.c
-@@ -5810,7 +5810,7 @@ s_collision_attack **collision_alloc_att
+@@ -5821,17 +5821,17 @@ s_collision_attack *collision_alloc_attack_instance(s_
+ //
+ // Allocate an empty collision attack list.
+ s_collision_attack **collision_alloc_attack_list()
+ {
+ s_collision_attack **result;
size_t alloc_size;
// Get amount of memory we'll need.
@@ -13,7 +18,17 @@ Avoid accidental rounding from abs()
// Allocate memory and get pointer.
result = malloc(alloc_size);
-@@ -5859,7 +5859,7 @@ s_collision_body **collision_alloc_body_
+
+ // Make sure the list is blank.
+ memset(result, 0, alloc_size);
+
+ // return result.
+@@ -5870,17 +5870,17 @@ s_collision_body *collision_alloc_body_instance(s_coll
+ //
+ // Allocate an empty collision attack list.
+ s_collision_body **collision_alloc_body_list()
+ {
+ s_collision_body **result;
size_t alloc_size;
// Get amount of memory we'll need.
@@ -22,6 +37,11 @@ Avoid accidental rounding from abs()
// Allocate memory and get pointer.
result = malloc(alloc_size);
+
+ // Make sure the list is blank.
+ memset(result, 0, alloc_size);
+
+ // return result.
@@ -8204,7 +8204,8 @@ size_t lcmScriptCopyBuffer(ArgList *argl
size_t lcmScriptDeleteMain(char **buf)