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

Incorrect format string in Windows stacktrace generator.

    XMLWordPrintable

Details

    • Bug
    • Status: Closed
    • Major - P3
    • Resolution: Fixed
    • None
    • 3.6.12, 4.0.9, 4.1.10
    • Logging
    • None
    • Fully Compatible
    • ALL
    • v4.0, v3.6
    • Hide

      The format string passed to _snprintf is "0x%llux". The 'u' and 'x' are mutally exclusive. Since the output is expected to be a hexadecimal number, the correct string is "0x%llx".

       
       
       
       
       
       
       
       

      Show
      The format string passed to _snprintf is "0x%llux". The 'u' and 'x' are mutally exclusive. Since the output is expected to be a hexadecimal number, the correct string is "0x%llx".                

    Description

      The following line reports incorrect stacktrace information due to an incorrect formatting string.

      src/mongo/util/stacktrace_windows.cpp:224

      _snprintf(symbolOffset.get(), bufferSize, "+"0x%llux", displacement64);

      The format string should be "0x%llx"

      Attachments

        Activity

          People

            john.festa@mongodb.com John Festa
            john.festa@mongodb.com John Festa
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: