VirtualBox

Changeset 1647 in vbox for trunk


Ignore:
Timestamp:
Mar 22, 2007 6:58:39 PM (18 years ago)
Author:
vboxsync
Message:

So far unsuccessful attempts to make Windows named pipes work properly - mainly disables stuff that should be done.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Devices/Serial/DrvNamedPipe.cpp

    r1534 r1647  
    117117                RTFILE tmp = pData->NamedPipe;
    118118                pData->NamedPipe = NIL_RTFILE;
     119#if 0
    119120                FlushFileBuffers((HANDLE)tmp);
     121#endif
    120122                DisconnectNamedPipe((HANDLE)tmp);
    121123                RTFileClose(tmp);
     
    168170    {
    169171        unsigned cbWritten;
     172#if 0
    170173        rc = RTFileWrite(pData->NamedPipe, pvBuf, *cbWrite, &cbWritten);
     174#else
     175        cbWritten = *cbWrite;
     176#endif
    171177        if (VBOX_FAILURE(rc))
    172178        {
     
    175181                RTFILE tmp = pData->NamedPipe;
    176182                pData->NamedPipe = NIL_RTFILE;
     183#if 0
    177184                FlushFileBuffers((HANDLE)tmp);
     185#endif
    178186                DisconnectNamedPipe((HANDLE)tmp);
    179187                RTFileClose(tmp);
     
    369377    {
    370378        /* Connect to the named pipe. */
    371         rc = RTFileOpen(&pData->NamedPipe, pData->pszLocation, RTFILE_O_READWRITE);
     379        rc = RTFileOpen(&pData->NamedPipe, pszLocation, RTFILE_O_READWRITE);
    372380        if (VBOX_FAILURE(rc))
    373381            return PDMDrvHlpVMSetError(pDrvIns, rc, RT_SRC_POS, N_("NamedPipe#%d failed to connect to named pipe %s"), pDrvIns->iInstance, pszLocation);
     
    387395    {
    388396        /* Bind address to the local socket. */
    389         RTFileDelete(pData->pszLocation);
     397        RTFileDelete(pszLocation);
    390398        if (bind(s, (struct sockaddr *)&addr, sizeof(addr)) == -1)
    391399            return PDMDrvHlpVMSetError(pDrvIns, RTErrConvertFromErrno(errno), RT_SRC_POS, N_("NamedPipe#%d failed to bind to local socket %s"), pDrvIns->iInstance, pszLocation);
     
    435443    if (pData->NamedPipe != NIL_RTFILE)
    436444    {
     445#if 0
    437446        FlushFileBuffers((HANDLE)pData->NamedPipe);
    438447        DisconnectNamedPipe((HANDLE)pData->NamedPipe);
     448#endif
    439449        RTFileClose(pData->NamedPipe);
    440450    }
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette