Exemplo n.º 1
0
void ShutDownNetwork()
{
    if (m_lowMemory) {
        CancelPackets();
        IPX_CloseSocket(m_socketId);
        qFree(m_clientAckIds);
        m_clientAckIds = nullptr;
        ReleaseFragmentedPackets();
        WriteToLog("Releasing low memory, ptr is %#x", m_lowMemory);
        FreeLowMemory(m_lowMemory);
        m_lowMemory = nullptr;
    }
}
Exemplo n.º 2
0
    // End current game structures.
PUBLIC void COM_EndGame(void) {
    if (COM_Links == NULL)
        return;
    if (COM_Type == COMT_IPX) {
        IPX_CloseSocket(IPXAddress.socket);
        IPX_DisposePackets(IPXPackets);
    } else if (COM_Type == COMT_SERIAL) {
        SER_EndComPort(&SerChannel.port);
    }
    DISPOSE(COM_Links);
    COM_MaxLinks = COM_NLinks = 0;
    COM_Type = COMT_NONE;
}