Cast pointers to long instead of int.
This commit is contained in:
parent
7625cdf7fc
commit
22c1ea5a54
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=35885
@ -181,7 +181,7 @@ int key;
|
||||
makesignal(from, "boarders from %s repelled", to);
|
||||
(void) sprintf(message, "killed in melee: %d. %s: %d",
|
||||
totalto, from->shipname, totalfrom);
|
||||
Write(W_SIGNAL, to, 1, (int) message, 0, 0, 0);
|
||||
Write(W_SIGNAL, to, 1, (long) message, 0, 0, 0);
|
||||
if (key)
|
||||
return 1;
|
||||
} else if (strengthto >= fromstrength * 3) {
|
||||
@ -213,10 +213,10 @@ int key;
|
||||
}
|
||||
(void) sprintf(message, "captured by the %s!",
|
||||
to->shipname);
|
||||
Write(W_SIGNAL, from, 1, (int) message, 0, 0, 0);
|
||||
Write(W_SIGNAL, from, 1, (long) message, 0, 0, 0);
|
||||
(void) sprintf(message, "killed in melee: %d. %s: %d",
|
||||
totalto, from->shipname, totalfrom);
|
||||
Write(W_SIGNAL, to, 1, (int) message, 0, 0, 0);
|
||||
Write(W_SIGNAL, to, 1, (long) message, 0, 0, 0);
|
||||
mento = 0;
|
||||
return 0;
|
||||
}
|
||||
|
@ -74,7 +74,7 @@ acceptsignal()
|
||||
;
|
||||
p[-1] = '"';
|
||||
*p = 0;
|
||||
Write(W_SIGNAL, ms, 1, (int)buf, 0, 0, 0);
|
||||
Write(W_SIGNAL, ms, 1, (long)buf, 0, 0, 0);
|
||||
}
|
||||
|
||||
lookout()
|
||||
|
@ -204,7 +204,7 @@ initialize()
|
||||
else
|
||||
captain[sizeof(captain) - 1] = '\0';
|
||||
}
|
||||
Write(W_CAPTAIN, ms, 1, (int)captain, 0, 0, 0);
|
||||
Write(W_CAPTAIN, ms, 1, (long)captain, 0, 0, 0);
|
||||
for (n = 0; n < 2; n++) {
|
||||
char buf[10];
|
||||
|
||||
@ -240,6 +240,6 @@ initialize()
|
||||
initscreen();
|
||||
draw_board();
|
||||
(void) sprintf(message, "Captain %s assuming command", captain);
|
||||
Write(W_SIGNAL, ms, 1, (int)message, 0, 0, 0);
|
||||
Write(W_SIGNAL, ms, 1, (long)message, 0, 0, 0);
|
||||
newturn();
|
||||
}
|
||||
|
@ -64,7 +64,7 @@ makesignal(from, fmt, ship, a, b, c)
|
||||
(void) sprintf(message, fmt,
|
||||
ship->shipname, colours(ship),
|
||||
sterncolour(ship), a, b, c);
|
||||
Write(W_SIGNAL, from, 1, (int)message, 0, 0, 0);
|
||||
Write(W_SIGNAL, from, 1, (long)message, 0, 0, 0);
|
||||
}
|
||||
|
||||
#include <sys/types.h>
|
||||
@ -194,7 +194,7 @@ Sync()
|
||||
*p = 0;
|
||||
for (p = buf; *p == ' '; p++)
|
||||
;
|
||||
a = (int)p;
|
||||
a = (long)p;
|
||||
b = c = d = 0;
|
||||
} else
|
||||
if (fscanf(sync_fp, "%d%d%d%d", &a, &b, &c, &d) != 4)
|
||||
@ -226,7 +226,7 @@ Sync()
|
||||
sync_update(type, ship, a, b, c, d)
|
||||
int type;
|
||||
register struct ship *ship;
|
||||
int a, b, c, d;
|
||||
long a, b, c, d;
|
||||
{
|
||||
switch (type) {
|
||||
case W_DBP: {
|
||||
|
Loading…
Reference in New Issue
Block a user