aboutsummaryrefslogtreecommitdiffstats
path: root/games
diff options
context:
space:
mode:
authorse <se@FreeBSD.org>2011-12-21 02:09:49 +0800
committerse <se@FreeBSD.org>2011-12-21 02:09:49 +0800
commitbedf0c1c7eef4968a6a3e64ef30039584c1164dc (patch)
tree40c0c8824412ce0f9e14b4dec8c106e290857d51 /games
parent256e67100cf300d068f65211aa9e357f23038431 (diff)
downloadfreebsd-ports-gnome-bedf0c1c7eef4968a6a3e64ef30039584c1164dc.tar.gz
freebsd-ports-gnome-bedf0c1c7eef4968a6a3e64ef30039584c1164dc.tar.zst
freebsd-ports-gnome-bedf0c1c7eef4968a6a3e64ef30039584c1164dc.zip
Fix type mismatch rejected by clang.
Diffstat (limited to 'games')
-rw-r--r--games/xroach/files/patch-ab105
1 files changed, 58 insertions, 47 deletions
diff --git a/games/xroach/files/patch-ab b/games/xroach/files/patch-ab
index f2f0774e18e1..ea392fd27ae5 100644
--- a/games/xroach/files/patch-ab
+++ b/games/xroach/files/patch-ab
@@ -1,47 +1,58 @@
-*** xroach.c.orig Sat May 4 21:18:41 1996
---- xroach.c Sat May 4 17:50:29 1996
-***************
-*** 96,114 ****
- /*
- Process command line options.
- */
-! for (ax=1; ax<ac; ax++) {
-! arg = av[ax];
- if (strcmp(arg, "-display") == 0) {
-! display_name = av[++ax];
- }
- else if (strcmp(arg, "-rc") == 0) {
-! roachColor = av[++ax];
- }
- else if (strcmp(arg, "-speed") == 0) {
-! roachSpeed = atof(av[++ax]);
- }
- else if (strcmp(arg, "-roaches") == 0) {
-! maxRoaches = strtol(av[++ax], (char **)NULL, 0);
- }
- else {
- Usage();
---- 96,118 ----
- /*
- Process command line options.
- */
-! for (ax=1; ax<ac; ) {
-! arg = av[ax++];
-!
-! if (ax >= ac)
-! Usage();
-!
- if (strcmp(arg, "-display") == 0) {
-! display_name = av[ax++];
- }
- else if (strcmp(arg, "-rc") == 0) {
-! roachColor = av[ax++];
- }
- else if (strcmp(arg, "-speed") == 0) {
-! roachSpeed = atof(av[ax++]);
- }
- else if (strcmp(arg, "-roaches") == 0) {
-! maxRoaches = strtol(av[ax++], (char **)NULL, 0);
- }
- else {
- Usage();
+--- xroach.c.orig 1993-06-04 21:47:09.000000000 +0200
++++ xroach.c 2011-12-20 19:03:53.816175581 +0100
+@@ -77,7 +77,7 @@
+ int MarkHiddenRoaches();
+ Pixel AllocNamedColor();
+
+-void
++int
+ main(ac, av)
+ int ac;
+ char *av[];
+@@ -96,19 +96,23 @@
+ /*
+ Process command line options.
+ */
+- for (ax=1; ax<ac; ax++) {
+- arg = av[ax];
++ for (ax=1; ax<ac; ) {
++ arg = av[ax++];
++
++ if (ax >= ac)
++ Usage();
++
+ if (strcmp(arg, "-display") == 0) {
+- display_name = av[++ax];
++ display_name = av[ax++];
+ }
+ else if (strcmp(arg, "-rc") == 0) {
+- roachColor = av[++ax];
++ roachColor = av[ax++];
+ }
+ else if (strcmp(arg, "-speed") == 0) {
+- roachSpeed = atof(av[++ax]);
++ roachSpeed = atof(av[ax++]);
+ }
+ else if (strcmp(arg, "-roaches") == 0) {
+- maxRoaches = strtol(av[++ax], (char **)NULL, 0);
++ maxRoaches = strtol(av[ax++], (char **)NULL, 0);
+ }
+ else {
+ Usage();
+@@ -212,6 +216,7 @@
+ CoverRoot();
+
+ XCloseDisplay(display);
++ return(0);
+ }
+
+ #define USEPRT(msg) fprintf(stderr, msg)
+@@ -465,7 +470,7 @@
+ Region covered;
+ Region visible;
+ Window *children;
+- int nChildren;
++ unsigned int nChildren;
+ Window dummy;
+ XWindowAttributes wa;
+ int wx;