Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. A question about QProcess communication

A question about QProcess communication

Scheduled Pinned Locked Moved General and Desktop
2 Posts 2 Posters 824 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • H Offline
    H Offline
    HYSuperman
    wrote on last edited by
    #1

    I'm using Qt to develop a front end and I attached it to an existing program. I created a new QProcess Object and use it to start the existing program.

    Here is the problem:
    The existing program (we'll call it A afterwards) prints it to the stdout and I use the following code to get the signal readyReadStandardOutput():
    @connect(A, SIGNAL(readyReadStandardOutput()), this, SLOT(updateOutPutEdit()));@
    the SLOT updateOutPutEdit() will read all the standard output and print it to the terminal.

    But I don't know whether A has a buffer or it's the QProcess' problem, the output will always stuck or display after a long time.

    I don't know why...Does Qt has a buffer between the parents' process and the forked one?

    1 Reply Last reply
    0
    • dheerendraD Offline
      dheerendraD Offline
      dheerendra
      Qt Champions 2022
      wrote on last edited by
      #2

      This may be issue with event processing. Are you trying to read this before even starting the event loop ?

      Dheerendra
      @Community Service
      Certified Qt Specialist
      http://www.pthinks.com

      1 Reply Last reply
      0

      • Login

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • Users
      • Groups
      • Search
      • Get Qt Extensions
      • Unsolved