RPC Server Support

RPC Shutdown Server

lgo_RpcShutdownServer()

Shutdown the LayGO RPC Server.

Syntax
#include "laygo.h"

LResult lgo_RpcShutdownServer
    (
        LServerId    serverId
    );
serverIdid of server to shut down
Description

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.

Return Values

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:

See Also

lgo_ConnectServer()
lgo_ConnectServerIp()
lgo_ConnectServerLocal()
lgo_DisconnectServer()
lgo_ShutdownServer()
lgo_RpcConnectServer()
lgo_RpcConnectServerIp()
lgo_RpcConnectServerLocal()
lgo_RpcDisconnectServer()

Example
if (lgo_ShutdownServer(0) < 0)
{
    exit(EXIT_FAILURE);
}