diff options
author | Leena Miettinen <riitta-leena.miettinen@digia.com> | 2014-10-20 12:17:24 +0200 |
---|---|---|
committer | Leena Miettinen <riitta-leena.miettinen@digia.com> | 2014-10-24 12:00:37 +0200 |
commit | 88e7a4f661da166e81171a3188f6290c40a2f748 (patch) | |
tree | 2b13078d7aab332552e2b3186535f3a0336b2c7a /src/corelib/io/qfile.cpp | |
parent | c4430ed02301c456dd591c88049ee22bc7dd9725 (diff) |
Doc: QFileDevice and QFile::setPermissions do not manipulate ACLs
Task-number: QTBUG-41271
Change-Id: Id97add8a6fdb7ce59020e833f6dc11744c9aaa7e
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Diffstat (limited to 'src/corelib/io/qfile.cpp')
-rw-r--r-- | src/corelib/io/qfile.cpp | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/src/corelib/io/qfile.cpp b/src/corelib/io/qfile.cpp index 6fe4c2455b..d3411abf10 100644 --- a/src/corelib/io/qfile.cpp +++ b/src/corelib/io/qfile.cpp @@ -206,6 +206,13 @@ QAbstractFileEngine *QFilePrivate::engine() const directory usually is not writable, but it is still possible to create files in it. + Qt's understanding of file permissions is limited, which affects especially + the \l QFile::setPermissions() function. On Windows, Qt will set only the + legacy read-only flag, and that only when none of the Write* flags are + passed. Qt does not manipulate access control lists (ACLs), which makes this + function mostly useless for NTFS volumes. It may still be of use for USB + sticks that use VFAT file systems. POSIX ACLs are not manipulated, either. + \sa QTextStream, QDataStream, QFileInfo, QDir, {The Qt Resource System} */ @@ -1063,9 +1070,12 @@ QFile::permissions(const QString &fileName) /*! Sets the permissions for the file to the \a permissions specified. - Returns \c true if successful, or false if the permissions cannot be + Returns \c true if successful, or \c false if the permissions cannot be modified. + \warning This function does not manipulate ACLs, which may limit its + effectiveness. + \sa permissions(), setFileName() */ |