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

QDir::mkpath regression

    XMLWordPrintable

Details

    • Bug
    • Resolution: Duplicate
    • Not Evaluated
    • None
    • 5.2.0 Alpha
    • Core: I/O
    • None
    • Windows 8.1

    Description

      This bug is not fixed in 5.2.0:
      https://bugreports.qt-project.org/browse/QTBUG-32314

      Simply try this, it will fail:
      Q_ASSERT(QDir().mkpath(QLatin1String("C:
      Users")));

      It is easy to track the problem: the Qt implementation relies on GetLastError, but this Microsoft API has a bug, as mentionned there:
      http://stackoverflow.com/questions/3570618/what-causes-createdirectory-to-return-error-access-denied

      Hence the Qt implementation fails.
      Qt code:
      qtbase\src\corelib\io\qfilesystemengine_win.cpp
      function:
      QFileSystemEngine::createDirectory

      I suggest to revert to the previous Qt implementation.

      Attachments

        Issue Links

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

          Activity

            People

              laknoll Lars Knoll
              jirauser26727 user-04d21 (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes