┌   ┐
54
└   ┘

summaryrefslogtreecommitdiff
path: root/src/views/renamedialog.cpp
diff options
context:
space:
mode:
authorMatthias Fuchs <[email protected]>2011-05-28 00:15:45 +0200
committerMatthias Fuchs <[email protected]>2011-05-28 01:31:45 +0200
commit3ed09520ad6402586238da22878453d95b558ac8 (patch)
tree2a8710e8eb7011030c3de8a4c9464394d97e47e1 /src/views/renamedialog.cpp
parente508685bae6a2171b0a681dbbe4764bfd16071e5 (diff)
Disallow renaming to names containing '/', names being equal to "." or "..".
BUG:211751 REVIEW:101454
Diffstat (limited to 'src/views/renamedialog.cpp')
-rw-r--r--src/views/renamedialog.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/views/renamedialog.cpp b/src/views/renamedialog.cpp
index 810562a51..a14ba77b7 100644
--- a/src/views/renamedialog.cpp
+++ b/src/views/renamedialog.cpp
@@ -148,7 +148,7 @@ void RenameDialog::slotButtonClicked(int button)
void RenameDialog::slotTextChanged(const QString& newName)
{
- bool enable = !newName.isEmpty();
+ bool enable = !newName.isEmpty() && (newName != QLatin1String("..")) && (newName != QLatin1String(".")) && !newName.contains('/');
if (enable) {
if (m_renameOneItem) {
enable = enable && (newName != m_newName);