aboutsummaryrefslogtreecommitdiffstats
path: root/games
diff options
context:
space:
mode:
authorjbeich <jbeich@FreeBSD.org>2018-01-21 01:46:12 +0800
committerjbeich <jbeich@FreeBSD.org>2018-01-21 01:46:12 +0800
commit7dea0e9fb37b58a24a4e0746e2cb80189c04bdf5 (patch)
tree650e3380c2325656c2803060285a691f99cafe90 /games
parent0596b70ef456e90f81d6a7cdf3438796ec25ed01 (diff)
downloadfreebsd-ports-gnome-7dea0e9fb37b58a24a4e0746e2cb80189c04bdf5.tar.gz
freebsd-ports-gnome-7dea0e9fb37b58a24a4e0746e2cb80189c04bdf5.tar.zst
freebsd-ports-gnome-7dea0e9fb37b58a24a4e0746e2cb80189c04bdf5.zip
games/avanor: unbreak build with Clang 6 (C++14 by default)
creature/Uniquem.cpp:628:11: error: cannot initialize return object of type 'int' with an rvalue of type 'nullptr_t' return NULL; ^~~~ /usr/include/sys/_null.h:37:14: note: expanded from macro 'NULL' #define NULL nullptr ^~~~~~~ Reported by: pkg-fallout
Diffstat (limited to 'games')
-rw-r--r--games/avanor/files/patch-creature__Uniquem.cpp19
1 files changed, 19 insertions, 0 deletions
diff --git a/games/avanor/files/patch-creature__Uniquem.cpp b/games/avanor/files/patch-creature__Uniquem.cpp
new file mode 100644
index 000000000000..bc35b2c62c80
--- /dev/null
+++ b/games/avanor/files/patch-creature__Uniquem.cpp
@@ -0,0 +1,19 @@
+creature/Uniquem.cpp:628:11: error: cannot initialize return object of type 'int' with an rvalue of
+ type 'nullptr_t'
+ return NULL;
+ ^~~~
+/usr/include/sys/_null.h:37:14: note: expanded from macro 'NULL'
+#define NULL nullptr
+ ^~~~~~~
+
+--- creature/Uniquem.cpp.orig 2003-12-10 07:03:57 UTC
++++ creature/Uniquem.cpp
+@@ -625,7 +625,7 @@ int XYohjishiro::onGiveItem(XCreature * giver, XItem *
+ (*it)->Item()->Identify(1);
+
+ }
+- return NULL;
++ return 0;
+ } else
+ {
+ char tbuf[256];