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

StringData::compare can illegally pass nullptr to memcmp

    • Fully Compatible
    • ALL
    • Platform B (10/30/15)

      It is undefined behavior to pass nullptr for either pointer argument to memcmp, however, StringData::compare does not guard against this. A default constructed StringData, for instance, has a nullptr _data member.

            Assignee:
            andrew.morrow@mongodb.com Andrew Morrow (Inactive)
            Reporter:
            andrew.morrow@mongodb.com Andrew Morrow (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: