GetPortsWithLimit
Retrieve up to limit ports according to the current SDK settings.
int GetPortsWithLimit(unsigned int limit, uint32_t** outPtr, int* outLen)
Parameters
limit: Maximum number of ports to return.
Return Value
int: 0 if success.
outPtr: Pointer to an array of ports (must be freed with FreeBuf).
outLen: Number of ports in outPtr.
Example
// example
uint32_t* out=NULL; int n=0;
GetPortsWithLimit(10,&out,&n);
if (out){ FreeBuf(out);}
Last updated
Was this helpful?