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

QWebEngineDownloadItem's suggested filename might be wrong when contains special character

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • P2: Important
    • 5.12.0 Beta 1
    • 5.11.2, 5.12
    • WebEngine
    • None
    • Linux/X11

    Description

      For example, in case of filename “foo bár test.txt” QWebEngineDownloadItem::path() returns “foo test.txt” for certain cases. Try the attached server example (web.py) with simplebrowser.

      Steps to reproduce:

      • Start web server: python web.py
      • Start simplebrowser and connect to web server: ./simplebrowser localhost:8000
      • Try links to check suggested filenames

      Actual result:
      When the server sends the filename in a http response header ( Content-Disposition: attachment; filename='foo b\xE1r test.txt' ) the word with accented character is dropped from filename:
      “foo bár test.txt” -> “foo test.txt”

      Expected result:
      In all cases the suggested filename is “foo bár test.txt”.

      Attachments

        1. web.py
          1 kB
          Tamas Zakor
        For Gerrit Dashboard: QTBUG-70288
        # Subject Branch Project Status CR V

        Activity

          People

            allan.jensen Allan Sandfeld Jensen
            ztamas Tamas Zakor
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes