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

Fix format strings given as char* (xcode build fix)

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major - P3
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 4.9.0
    • Component/s: Internal Code
    • Labels:
      None
    • Backwards Compatibility:
      Fully Compatible
    • Sprint:
      Service Arch 2021-03-22

      Description

      For example:

      -            static constexpr auto errorMsg =
      +            static constexpr auto& errorMsg =
                       "Failed to complete construction of sharding DDL coordinator";
      

      Without the ampersand, the string literal decays to a pointer.
      FMT_STRING can't use pointers. It needs arrays.

        Attachments

          Activity

            People

            Assignee:
            billy.donahue Billy Donahue
            Reporter:
            billy.donahue Billy Donahue
            Participants:
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: