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

QUrl's constructor should accept strings without scheme as local paths

    XMLWordPrintable

    Details

    • Type: Suggestion
    • Status: Closed
    • Priority: P0: Blocker
    • Resolution: Done
    • Affects Version/s: 4.8.0
    • Fix Version/s: 4.8.1
    • Component/s: Core: URL Handling
    • Labels:
      None
    • Environment:

      Ark Linux dockyard-devel, gcc 4.6, eglibc 2.14

    • Commits:
      182acb541a7b8ac0edca842fdc867751df723f50

      Description

      This piece of code:

      QUrl u=QUrl::fromEncoded("/etc/passwd");
      qDebug() << u.toLocalFile();

      produces (as expected) "/etc/passwd" on Qt 4.7.x - on Qt 4.8.x, it produces ""

      Qt5's QUrl constructor should work like Qt4's QUrl::fromEncoded, but it should decode strings without path as local files and set scheme() to "file".

        Attachments

          Issue Links

          For Gerrit Dashboard: QTBUG-19827
          # Subject Branch Project Status CR V

            Activity

              People

              Assignee:
              ahaapane Aapo Haapanen (closed Nokia identity) (Inactive)
              Reporter:
              bero Bernhard Rosenkränzer
              Votes:
              1 Vote for this issue
              Watchers:
              7 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:

                  Gerrit Reviews

                  There are no open Gerrit changes