diff options
author | Simon Rettberg | 2015-08-11 16:31:30 +0200 |
---|---|---|
committer | Simon Rettberg | 2015-08-11 16:31:30 +0200 |
commit | 7ba1a00c9927905732ad72211562afe0b5072f1d (patch) | |
tree | ede767d50b86d199704904133d0fa2792f0dbb5e /dozentenmodulserver/src/main/java/org/openslx/bwlp/sat/fileserv/FileServer.java | |
parent | [server] Don't swallow exceptions in User.getOrFail (diff) | |
download | tutor-module-7ba1a00c9927905732ad72211562afe0b5072f1d.tar.gz tutor-module-7ba1a00c9927905732ad72211562afe0b5072f1d.tar.xz tutor-module-7ba1a00c9927905732ad72211562afe0b5072f1d.zip |
[server] Create proper path for file download
Diffstat (limited to 'dozentenmodulserver/src/main/java/org/openslx/bwlp/sat/fileserv/FileServer.java')
-rw-r--r-- | dozentenmodulserver/src/main/java/org/openslx/bwlp/sat/fileserv/FileServer.java | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/dozentenmodulserver/src/main/java/org/openslx/bwlp/sat/fileserv/FileServer.java b/dozentenmodulserver/src/main/java/org/openslx/bwlp/sat/fileserv/FileServer.java index d1136c2b..d071e72d 100644 --- a/dozentenmodulserver/src/main/java/org/openslx/bwlp/sat/fileserv/FileServer.java +++ b/dozentenmodulserver/src/main/java/org/openslx/bwlp/sat/fileserv/FileServer.java @@ -157,10 +157,10 @@ public class FileServer implements IncomingEvent { if (activeDownloads > Constants.MAX_DOWNLOADS) throw new TTransferRejectedException("Server busy. Too many running downloads."); // Determine src file and go - File srcFile = new File(Configuration.getCurrentVmStorePath(), localImageData.filePath); + File srcFile = new File(Configuration.getVmStoreBasePath(), localImageData.filePath); if (!srcFile.canRead()) { LOGGER.warn("Rejecting download of VID " + localImageData.imageVersionId + ": Missing " - + srcFile.getName()); + + srcFile.getPath()); // TODO: Mark as invalid in DB throw new TTransferRejectedException("File missing on server"); } |