lgo_RpcShutdownServer()
Shutdown the LayGO RPC Server.
#include "laygo.h" LResult lgo_RpcShutdownServer ( LServerId serverId );
serverId | id of server to shut down |
lgo_RpcShutdownServer() causes the specified LayGO RPC Server to terminate. A shutdown request will only succeed if all clients have disconnected from the server. An application which calls lgo_RpcShutdownServer() cannot be connected to any server.
If successful, lgo_RpcShutdownServer() returns a non-negative value. Otherwise, it returns a negative value indicating the reason it failed. Possible unsuccessful return values are:
lgo_ConnectServer()
lgo_ConnectServerIp()
lgo_ConnectServerLocal()
lgo_DisconnectServer()
lgo_ShutdownServer()
lgo_RpcConnectServer()
lgo_RpcConnectServerIp()
lgo_RpcConnectServerLocal()
lgo_RpcDisconnectServer()
if (lgo_ShutdownServer(0) < 0) { exit(EXIT_FAILURE); }