Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-5287

Errors in MapViewOfFile() might return incomplete data in a query

    • Type: Icon: Bug Bug
    • Resolution: Done
    • Priority: Icon: Major - P3 Major - P3
    • 2.1.1
    • Affects Version/s: 2.1.0
    • Component/s: Logging, Storage
    • None
    • Environment:
      Windows
    • Windows

      Right now, if MapViewOfFile() returns an error, we just log a message and blindly continue. This can result in incomplete data being returned for a given query, as illustrated by the failing update.js test on Windows.

      We should throw an exception (or massert) when the Windows function returns an error, to prevent the query from proceeding.
      I see that calls to mmap() also just return 0 and do not throw an exception, so perhaps we should throw here as well?
      The alternative is to check all the places where we're using MemoryMappedFile member functions and ensure we're not ignoring their return statuses.

            Assignee:
            tad Tad Marshall
            Reporter:
            milkie@mongodb.com Eric Milkie
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: