Uploaded image for project: 'WiredTiger'
  1. WiredTiger
  2. WT-2569

win_handle_read should always call GetLastError on error

    • Type: Icon: Bug Bug
    • Resolution: Done
    • Priority: Icon: Major - P3 Major - P3
    • WT2.9.0
    • Affects Version/s: WT2.8.0
    • Component/s: None
    • None
    • Platforms 13 (04/22/16)

      Check nr in the code below is POSIX read api semantics but is wrong for Windows. This causes the WIndows code to lose error information if read fails.

                      if (!ReadFile(fh->filehandle, addr, chunk, &nr, &overlapped))
                              WT_RET_MSG(session,
                                 nr == 0 ? WT_ERROR : __wt_getlasterror(),
                                  "%s: handle-read: ReadFile: failed to read %lu "
                                  "bytes at offset %" PRIuMAX,
      

            Assignee:
            mark.benvenuto@mongodb.com Mark Benvenuto
            Reporter:
            mark.benvenuto@mongodb.com Mark Benvenuto
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: