Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-74074

QProcess startDetached is not setting an environment for the new process

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: P2: Important
    • Resolution: Invalid
    • Affects Version/s: 5.12.1
    • Fix Version/s: None
    • Component/s: Core: I/O
    • Labels:
      None
    • Platform/s:
      Windows

      Description

      Setting an env variable to, say QProcess exeB, is not available to another process started with exeB.startDetached. It is working fine with exeB.start.

      1. Execute the attached sample.
      2. out.txt file is generated via AnotherProcess having all the env variable.
      3. Newly set variable "PYTHONHOME"= "NewVariable" is not listed in out.txt.
      4. If process is started with exeB.start(), it works fine.

      Attaching the source code for AnotherProcess for reference.

        Attachments

        1. AnotherProcess.zip
          3 kB
        2. qtbug74074.zip
          9.79 MB
        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

            Assignee:
            thiago Thiago Macieira
            Reporter:
            shmittal Shveta Mittal
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:

                Gerrit Reviews

                There are no open Gerrit changes