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

qDebug() replaces newlines with \n unless called with .noquote()

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Invalid
    • Icon: Not Evaluated Not Evaluated
    • None
    • 5.5.1
    • Core: Other
    • None
    • OpenSuSE 42.1
      Linux 4.1.15-8-default #1 SMP PREEMPT Wed Jan 20 16:41:00 UTC 2016 (0e3b3ab) x86_64 x86_64 x86_64 GNU/Linux

      Previously, when QString containing newline characters was fed into qDebug() using the << operator, qDebug would print that string and make a newline in stderr everywhere where a newline character was in that string.

      Now it just prints "\n", unless you append ".noquote()".

      This forces anyone who used qDebug to output QStrings with multiline error descriptions to run through the codebase and replace qDebug() calls with qDebug().noquote().

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

            thiago Thiago Macieira
            scumcoder Daniil Larionov
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved:

                There are no open Gerrit changes