mirror of https://github.com/ARMmbed/mbed-os.git
Implement the NSAPI_KEEPINTVL in the LWIPInterface
parent
187958b1f8
commit
3c180b3f30
|
@ -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;
|
||||
|
||||
|
|
Loading…
Reference in New Issue