Subagent Exits If Idle
Hi,
I'm having a problem with my SNMP subagent. If I leave it running overnight with no polling or trapping, the library will eventually exit with the message:
select() failed [errno: Invalid argument(22)]
... It doesn't signal or anything, just exits.
My agent_select_info callback is as follows:
void agent_select_info(fd_set *fdset, int *numfds)
{
FD_SET(g_sockfd, fdset);
*numfds = FD_SETSIZE;
}
... where FD_SETSIZE == 1024.
- AndyC
[512 byte] By [
andyc_2k] at [2007-11-26 5:53:40]

# 1
Hi,
I have the same problem.
Any ideas? Thanks a lot!!
> Hi,
>
> I'm having a problem with my SNMP subagent. If I leave
> it running overnight with no polling or trapping, the
> library will eventually exit with the message:
>
>select() failed [errno: Invalid argument(22)]
>
> ... It doesn't signal or anything, just exits.
> My agent_select_info callback is as follows:
>
> void agent_select_info(fd_set *fdset, int *numfds)
> {
>FD_SET(g_sockfd, fdset);
>*numfds = FD_SETSIZE;
> }
>
> ... where FD_SETSIZE == 1024.
>
> - AndyC