Changeset 3776 for trunk


Ignore:
Timestamp:
Mar 22, 2012, 1:19:05 PM (13 years ago)
Author:
bird
Message:

read/fhOs2FileWrite: Translate ERROR_PIPE_NOT_CONNECTED when returned by DosRead to a 0 byte read / EOF indicator. Only named pipes will return this status and only when the pipe was actively disconnected. Fixes #247.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/libc/src/kNIX/os2/fhOS2File.c

    r3770 r3776  
    161161        rc = DosWrite(pFH->hNative, pvBuf, cbToWrite, &cbActuallyWritten);
    162162
    163 
    164163    /* deal with the return code. */
    165164    if (!rc)
     
    169168    }
    170169    *pcbWritten = 0;
     170    if (rc == ERROR_PIPE_NOT_CONNECTED)
     171        LIBCLOG_RETURN_MSG(0, "ret 0 *pcbWritten=0 [pipe-disconnect]\n");
    171172    if (rc > 0)
    172173        rc = -__libc_back_native2errno(rc);
Note: See TracChangeset for help on using the changeset viewer.