version 1.180 | | version 1.181 |
---|
| | |
/* | | /* |
* static char *rcsid_player_c = | | * static char *rcsid_player_c = |
* "$Id: player.c,v 1.180 2005/10/18 16:54:31 gros Exp $"; | | * "$Id: player.c,v 1.181 2005/10/28 18:19:53 akirschbaum Exp $"; |
*/ | | */ |
| | |
/* | | /* |
| | |
| | |
p=get_player(NULL); | | p=get_player(NULL); |
memcpy(&p->socket, ns, sizeof(NewSocket)); | | memcpy(&p->socket, ns, sizeof(NewSocket)); |
| | p->socket.faces_sent = malloc(p->socket.faces_sent_len*sizeof(*p->socket.faces_sent)); |
| | if(p->socket.faces_sent == NULL) |
| | fatal(OUT_OF_MEMORY); |
| | memcpy(p->socket.faces_sent, ns->faces_sent, p->socket.faces_sent_len*sizeof(*p->socket.faces_sent)); |
/* Needed because the socket we just copied over needs to be cleared. | | /* Needed because the socket we just copied over needs to be cleared. |
* Note that this can result in a client reset if there is partial data | | * Note that this can result in a client reset if there is partial data |
* on the uncoming socket. | | * on the uncoming socket. |