Vanilla Netrek Server Development Archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[VANILLA-L:721] Re: Eject and Eject again bug
Quoting James Cameron (cameron@stl.dec.com):
> Hmm. j->voting is part of player struct, and is defined as a time_t,
> so what is time_t on your machine, is it signed? Because -1 is not a
> useful value if it isn't a signed type.
>
> daemonII.c sets it to zero.
>
> I haven't yet figured out what -1 is used for.
/* Reset the Votes for this item since it passed */
for (i = 0, j = &players[i]; i < MAXPLAYER; i++, j++) {
j->voting[what] = 0;
}
THAT was it! Because voting is defined as time_t I cannot be negative,
so I changed it to 0 and the vote/ejection code works fine.
I'll submit patches as soon I as take out all the debugging code.
--
Bob Tanner <tanner@real-time.com> | Phone : 612.943.8700
http://www.real-time.com | Fax : 612.943.8300
Key fingerprint = 6C E9 51 4F D5 3E 4C 66 62 A9 10 E5 35 85 39 D9
+
++ Vanilla-l Mailing List ++
To unsubscribe: send "unsubscribe vanilla-l" to majordomo@real-time.com
For more information: http://archives.real-time.com
References: