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

ModifierPush::init may coerce NaN to an integer

    XMLWordPrintable

    Details

    • Backwards Compatibility:
      Fully Compatible
    • Operating System:
      ALL
    • Steps To Reproduce:
      Hide

      Run the modifier_push_test under the undefined behavior sanitizer

      Show
      Run the modifier_push_test under the undefined behavior sanitizer
    • Sprint:
      Platforms 13 (04/22/16)

      Description

      ModifierPush::init, while validating parameters, reads the same value once as a double and once as an integer and compares them. However, if the double is not zero and also not normal, the behavior is undefined. For non-zero double values, the double value should be checked with std::isnormal before coercing to an integer.

        Attachments

          Activity

            People

            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: