dangling-gsl warning in libwixhelper.cpp

XMLWordPrintable

    • Type: Bug
    • Resolution: Fixed
    • Priority: P4
    • 22
    • Affects Version/s: 20, 21, 22
    • Component/s: tools
    • b09

      While experimenting with clang build on Windows, I noticed the following warning:

      jdk\open\src\jdk.jpackage\windows\native\libwixhelper\libwixhelper.cpp(75,36): warning: object backing the pointer will be destroyed at the end of the full-expression [-Wdangling-gsl]
          const LPCTSTR upgradeCodeStr = upgradeCode.toMsiString().c_str();
                                         ^~~~~~~~~~~~~~~~~~~~~~~~~

      The code was recently introduced in JDK-8283707.

            Assignee:
            Alexey Semenyuk
            Reporter:
            Daniel Jelinski
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: