VBoxIPC.cpp revision 340134cc37fb7a9b4498a2b13df2fa340a1824c0
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync * VboxIPC - IPC thread.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync * Copyright (C) 2010 Oracle Corporation
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync * This file is part of VirtualBox Open Source Edition (OSE), as
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync * available from http://www.virtualbox.org. This file is free software;
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync * you can redistribute it and/or modify it under the terms of the GNU
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync * General Public License (GPL) as published by the Free Software
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync * Foundation, in version 2 as it comes in the "COPYING" file of the
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync * VirtualBox OSE distribution. VirtualBox OSE is distributed in the
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync * hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncint VBoxIPCReadMessage(PVBOXIPCCONTEXT pCtx, BYTE *pMessage, DWORD cbMessage)
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync if (!ReadFile(pCtx->hPipe, pMessage, cbMessage, &dwRead, 0))
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsyncint VBoxIPCWriteMessage(PVBOXIPCCONTEXT pCtx, BYTE *pMessage, DWORD cbMessage)
4fd606d1f5abe38e1f42c38de1d2e895166bd0f4vboxsync if (!WriteFile(pCtx->hPipe, pMessage, cbMessage, &cbWritten, 0))
return rc;
*pfStartThread = false;
&sa);
*pfStartThread = true;
return rc;
bool fTerminate = false;
? TRUE
if (fConnected)
case VBOXTRAYIPCMSGTYPE_QUIT:
fTerminate = true;
fTerminate = true;
} while (!fTerminate);