RtfwStopNetwork
RtfwStopNetwork stops the RT-TCP/IP Stack.
Syntax
bool RtfwStopNetwork( unsigned int timeout );
Parameters
timeout
Specifies the amount of time (in seconds) this function will wait for the Stack to stop. If this value is zero, the timeout is 30 seconds.
Return Value
The function returns true if it succeeds. Otherwise, it returns false. Call GetLastError for additional error information.
Possible error codes:
Error Code | Meaning |
---|---|
RT_ERROR_NETWORK_NOT_STARTED | The RT-TCP/IP Stack is not started, but an operation was attempted that requires it to be started. |
RT_ERROR_NETWORK_CLIENTS_EXIST | The RT-TCP/IP Stack cannot be stopped, because one or more stack client processes are still running. |
RT_ERROR_NETWORK_STOP_TIMEOUT | A timeout occurred waiting for the RT-TCP/IP Stack to stop. |
RT_ERROR_NETWORK_STARTSTOP_LOCK_FAILURE | Failed to obtain the lock to serialize starting/stopping the RTX64 Subsystem. |
Remarks
If the Stack does not stop within the specified timeout period, this function fails and sets the last error value to RT_ERROR_NETWORK_STOP_TIMEOUT.
Requirements
Minimum Required Version | RTX64 3.4 |
Header | RtfwAPI.h |
Library | RtfwAPI.lib |
See Also: