tfHttpdUserSetSockopt
Table of Contents >> Application Reference >> Web Server
| #include <trsocket.h> |
| int tfHttpdUserSetSockopt | ( |
| ttHttpdUserSrvHandle userSrvHandle, | |
| int protocolLevel, | |
| int optionName, | |
| const char TM_FAR * optionValuePtr, | |
| int optionLength | |
| ); |
Function Description
This API that allows the user to change the socket options on the web server listening socket using the server handle returned by tfHttpdUserStart(). User should call tfHttpdUserSetSockopt() before tfHttpdUserExecute() is called. This call is similar to setsockopt(). The only difference is that it takes a user server handle as its first argument instead of a socket descriptor.
Parameters
- userSrvHandle
- Handler returned by tfHttpdUserStart
- protocolLevel
- The protocol option level. Valid values are:
- SOL_SOCKET for Socket level protocol options
- IP_PROTOIP for IP level protocol options
- IP_PROTOTCP for TCP level protocol options
- The protocol option level. Valid values are:
- optionName
- The option name to set. See setsockopt() for a full list of options.
- optionValuePtr
- The pointer to a user variable into which the option value is returned.
- optionLength
- The size of the user variable. It is the size of the option data type (see setsockopt()).