summaryrefslogtreecommitdiffstats
path: root/src/downloadmanager.cpp
diff options
context:
space:
mode:
authorNiklas Goby2011-03-23 12:18:01 +0100
committerNiklas Goby2011-03-23 12:18:01 +0100
commit06de7af9a08a7182e4ea253370d7ec377f0e5a18 (patch)
treed84b35a776166ea7df1715baeb26ba472955f1a3 /src/downloadmanager.cpp
parentsome tries with the qrc and jquery delivery (diff)
parenttrigger file path definable (diff)
downloadfbgui-06de7af9a08a7182e4ea253370d7ec377f0e5a18.tar.gz
fbgui-06de7af9a08a7182e4ea253370d7ec377f0e5a18.tar.xz
fbgui-06de7af9a08a7182e4ea253370d7ec377f0e5a18.zip
Merge branch 'master' of git.openslx.org:lsfks/master-teamprojekt/fbgui
Diffstat (limited to 'src/downloadmanager.cpp')
-rw-r--r--src/downloadmanager.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/downloadmanager.cpp b/src/downloadmanager.cpp
index 47582c8..ab1b0ad 100644
--- a/src/downloadmanager.cpp
+++ b/src/downloadmanager.cpp
@@ -164,6 +164,7 @@ void DownloadManager::downloadFinished()
// check for errors
if (currentDownload->error()){
currentDownload->deleteLater();
+ outfile.close();
outfile.remove();
int statusCode = currentDownload->attribute(QNetworkRequest::HttpStatusCodeAttribute).toInt();
qxtLog->debug() << "Download of " << currentDownload->url().toString()
@@ -171,6 +172,7 @@ void DownloadManager::downloadFinished()
emit notify(QString("Download failed! HTTP Status Code: %1").arg(statusCode));
}
else{
+ completeKCL();
// end download
currentDownload->deleteLater();
outfile.close();
@@ -188,6 +190,14 @@ void DownloadManager::downloadFinished()
}
startNextDownload();
}
+// ----------------------------------------------------------------------------------------
+void DownloadManager::completeKCL(){
+ // check if current download is kcl
+ if (outfile.fileName() == downloadDir.absoluteFilePath("kcl")){
+ qxtLog->debug() << "Completing kernel command line ...";
+ outfile.write(" session=" + sessionID.toUtf8());
+ }
+}
/********************************************************************************************************
*
** dead code: Header filename fetching & renaming **