From 36af7fe678f41bbff2598b1e681a4a02ec3e2291 Mon Sep 17 00:00:00 2001 From: David Faure Date: Fri, 7 Feb 2014 14:14:25 +0100 Subject: QDir::tempPath: make fallback code more readable. This is a no-op because QDir::cleanPath() already takes care of removing the trailing slash. Change-Id: Ic19d9a9dd7e377e04447c3ebc776b025f5f0c43a Reviewed-by: Friedemann Kleint --- src/corelib/io/qfilesystemengine_unix.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/corelib') diff --git a/src/corelib/io/qfilesystemengine_unix.cpp b/src/corelib/io/qfilesystemengine_unix.cpp index e6b4e5f754..2327c11c69 100644 --- a/src/corelib/io/qfilesystemengine_unix.cpp +++ b/src/corelib/io/qfilesystemengine_unix.cpp @@ -721,13 +721,13 @@ QString QFileSystemEngine::tempPath() if (temp.isEmpty()) { qWarning("Neither the TEMP nor the TMPDIR environment variable is set, falling back to /tmp."); - temp = QLatin1String("/tmp/"); + temp = QLatin1String("/tmp"); } return QDir::cleanPath(temp); #else QString temp = QFile::decodeName(qgetenv("TMPDIR")); if (temp.isEmpty()) - temp = QLatin1String("/tmp/"); + temp = QLatin1String("/tmp"); return QDir::cleanPath(temp); #endif } -- cgit v1.2.3