QProcess output lines are truncated to 80 columns
MuratUrsavas last edited by
I'm having an interesting issue with QProcess. If I debug the process (a standard Linux command) and try to get the output with readAllOutputStandard(), I see that each line has been truncated to 80 characters.
If I debug it via running it in terminal or just run it with or without terminal everything seems fine, line lengths are OK and I can get all output without any truncation.
Why is there such difference and how can I disable (or increase) this 80 character limit on the QProcess output while debugging?
JonB last edited by
Start by showing what command you actually execute, plus your code dealing with the
QProcessand reading output? And I don't understand what/how you are saying you are debugging?
AnneRanch last edited by
If I debug the process (a standard Linux command) and try to get the output with readAllOutputStandard(), I see that each line has been truncated to 80 characters.
That should be sufficient description of the issue.
My current usage "shows " almost 200 characters.
In my search I found QProcess has inherited form QIODevice
and this note
qint64 QIODevice::peek(char * data, qint64 maxSize)
Reads at most maxSize bytes from the device into data, without side effects (i.e., if you call read() after peek(), you will get the same data). Returns the number of bytes read. If an error occurs, such as when attempting to peek a device opened in WriteOnly mode, this function returns -1.
Perhaps further search for "maxSize" could answer the question.