Implement the NSAPI_KEEPINTVL in the LWIPInterface

geky 2016-06-08 20:06:52 +01:00
parent 187958b1f8
commit 3c180b3f30
1 changed files with 7 additions and 0 deletions

View File

@ -555,6 +555,13 @@ int LWIPInterface::setsockopt(void *handle, int level, int optname, const void *
}
s->tcp->so_options |= SOF_KEEPALIVE;
return 0;
case NSAPI_KEEPINTVL:
if (optlen != sizeof(int) || s->proto != NSAPI_TCP) {
return NSAPI_ERROR_UNSUPPORTED;
}
s->tcp->keep_intvl = *(int*)optval;
return 0;