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

Default implementations of sleepsecs and sleepmicros do not handle EINTR

    XMLWordPrintableJSON

Details

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Major - P3 Major - P3
    • 3.2.0-rc3
    • None
    • Internal Code
    • None
    • Fully Compatible
    • ALL
    • Platform C (11/20/15)

    Description

      The default implementation of these functions uses nanosleep which can return with EINTR, but this return value is not handled. To be strictly correct, the functions must be written as loops which evaluate whether the intended interval has elapsed if woken with EINTR and continuing with the 'rmtp' interval.

      In addition, these function log to std::cout on a non-zero return from nanosleep, which hardly seems helpful.

      Attachments

        Activity

          People

            mira.carey@mongodb.com Mira Carey
            andrew.morrow@mongodb.com Andrew Morrow (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: