From 189148e70128d037f7bd541f2c1f21aa783000d9 Mon Sep 17 00:00:00 2001 From: Dominik Riebeling Date: Sun, 27 Jan 2013 20:09:00 +0100 Subject: Set global cache immediately on startup. Setting the cache later can result in the system trying to create cache files in the current working directory, since an empty cache path will be treated as current directory. If this happens set the system temporary path. Change-Id: I1623330013d387a966015edd0e1d278c922d9475 --- rbutil/rbutilqt/rbutilqt.cpp | 3 +++ 1 file changed, 3 insertions(+) (limited to 'rbutil') diff --git a/rbutil/rbutilqt/rbutilqt.cpp b/rbutil/rbutilqt/rbutilqt.cpp index b85c2db411..5ea5002c8f 100644 --- a/rbutil/rbutilqt/rbutilqt.cpp +++ b/rbutil/rbutilqt/rbutilqt.cpp @@ -116,6 +116,9 @@ RbUtilQt::RbUtilQt(QWidget *parent) : QMainWindow(parent) /* eject funtionality is only implemented on W32 right now. */ ui.buttonEject->setEnabled(false); #endif + QString c = RbSettings::value(RbSettings::CachePath).toString(); + if(c.isEmpty()) c = QDir::tempPath(); + HttpGet::setGlobalCache(c); updateDevice(); downloadInfo(); -- cgit v1.2.3