Better handling of keep-alive requests

This commit is contained in:
Joseph C. Lehner 2016-02-13 23:49:38 +01:00
parent 34698c8813
commit 9f51230d21

2
nmrp.c
View file

@ -586,6 +586,8 @@ int nmrp_do(struct nmrpd_args *args)
break;
case NMRP_C_KEEP_ALIVE_REQ:
tx.msg.code = NMRP_C_KEEP_ALIVE_ACK;
ethsock_set_timeout(sock, 15000);
printf("Received keep-alive request.\n");
break;
case NMRP_C_CLOSE_REQ:
tx.msg.code = NMRP_C_CLOSE_ACK;