Uploaded image for project: 'Qt Creator'
  1. Qt Creator
  2. QTCREATORBUG-24311

Fail to detect visual studio 2019 build tools for non-English locale

    XMLWordPrintable

    Details

    • Platform/s:
      Windows
    • Commits:
      4c02f807c1d71dcd1065c35c1b497d94c090dca6 (qt-creator/qt-creator/4.13)

      Description

      QtCreator is using vswhere to detect visual studio products, but if the OS is in non-English locale (e.g. Traditional Chinese), the detection failed with the message:

       

      Could not parse json document from vswhere output.

       

      It appears QtCreator is using the command:

      vswhere -products * -prerelease -legacy -format json -utf8

       

      The output is already in UTF-8, but SynchronousProcessResponse is using QTextCodec::codecForLocale() to parse the output, thus non-English locale will see the corrupted output.

       

      It looks like you should somehow set the text codec to QTextCodec::codecForName("UTF8") before getting the stdOut() or just use allRawOutput()

        Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

            Assignee:
            kandeler Christian Kandeler
            Reporter:
            steve.k.chiu Steve K. Chiu
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:

                Gerrit Reviews

                There are no open Gerrit changes