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

QSerialPortInfo::availablePorts() have problem...

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • P4: Low
    • 5.3.2
    • 5.3.0
    • Serial Port
    • None
    • Windows 7
      Qt 5.3.0
      MinGW 32bit

    Description

      In Windows 7 with QT 5.3.0 (minGW 32bit)

      The function QSerialPortInfo::availablePorts()returns too many ports.
      The return RS232 ports have an empty description and are not present in Windows system.
      This bug don't exist on the previous version Qt 5.2

      To prevent this bug, I use this code like below:

      QList<QSerialPortInfo> ports= QSerialPortInfo::availablePorts();
      for (int i= 0; i<ports.size(); i++)
      if(!ports.at.description().isEmpty()) // for correct the bug !!!
      qDebug()<<ports.at.portName();

      Best regards

      Nicolas LLASER

      computer science teacher in France

      Attachments

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

        Activity

          People

            kuzulis Denis Shienkov
            nicolas314 Nicolas LLASER
            Votes:
            1 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes