# HG changeset patch # User gongo # Date 1163116273 0 # Node ID 0c533df35784cf859d0029c29c545e55b2e8a392 # Parent 22821fc0dddb5b1877e770aa2f47967e2a6d4ad8 *** empty log message *** diff -r 22821fc0dddb -r 0c533df35784 linda.c --- a/linda.c Thu Nov 09 19:08:22 2006 +0000 +++ b/linda.c Thu Nov 09 23:51:13 2006 +0000 @@ -116,22 +116,14 @@ } } -static Bool +static void linda_set_schedule(void *func, int mode) { - char *reply = NULL; int id = game.play_id; - reply = psx_reply(linda_seq[id]); - if (reply) { - linda_seq[id] = psx_in(id); - psx_free(reply); - return FALSE; - } else { - sche_func = func; - send_packet(id, mode, game.car_id, game.course_id, NULL); - return TRUE; - } + linda_seq[id] = psx_in(id); + sche_func = func; + send_packet(id, mode, game.car_id, game.course_id, NULL); } static Bool @@ -152,10 +144,7 @@ } if (p == 1 && connect == CLIENT_MAX) { - if (linda_set_schedule(linda_sche_wait_ready0, MODE_WAIT_READY) == TRUE) - return TRUE; - else - return FALSE; + linda_set_schedule(linda_sche_wait_ready0, MODE_WAIT_READY); } else { return FALSE; } @@ -724,10 +713,10 @@ if (my_id == PLAYER_1P) { sche_func = &linda_sche_wait0; - send_packet(game.play_id, MODE_WAIT, 1, 1, NULL); } else { sche_func = &linda_sche_wait1; - send_packet(game.play_id, MODE_WAIT, 1, 1, NULL); } + send_packet(game.play_id, MODE_WAIT, 1, 1, NULL); + return my_id; }