aboutsummaryrefslogtreecommitdiff
path: root/backends/cloud
diff options
context:
space:
mode:
authorD G Turner2017-02-28 20:42:17 +0000
committerD G Turner2017-02-28 20:42:17 +0000
commitb779f20502308c8db5c168c789f8867a13c8020b (patch)
tree13c1b120252b0d5e79602e76a8948454ec16fbf0 /backends/cloud
parentae4f96f7ba5b3d38eaa5c41dc5e6808a3c0a3d89 (diff)
downloadscummvm-rg350-b779f20502308c8db5c168c789f8867a13c8020b.tar.gz
scummvm-rg350-b779f20502308c8db5c168c789f8867a13c8020b.tar.bz2
scummvm-rg350-b779f20502308c8db5c168c789f8867a13c8020b.zip
CLOUD: Fix GCC Unused Variable Warning.
This variable is not used as the constructors for the storage type classes store the resulting objects into the Cloud Manager using replaceStorage(this) instead.
Diffstat (limited to 'backends/cloud')
-rw-r--r--backends/cloud/cloudmanager.cpp11
1 files changed, 4 insertions, 7 deletions
diff --git a/backends/cloud/cloudmanager.cpp b/backends/cloud/cloudmanager.cpp
index 4fb38ad779..5519e4baab 100644
--- a/backends/cloud/cloudmanager.cpp
+++ b/backends/cloud/cloudmanager.cpp
@@ -253,27 +253,24 @@ void CloudManager::setStorageLastSync(uint32 index, Common::String date) {
void CloudManager::connectStorage(uint32 index, Common::String code) {
freeStorages();
- Storage *storage = nullptr;
switch (index) {
case kStorageDropboxId:
- storage = new Dropbox::DropboxStorage(code);
+ new Dropbox::DropboxStorage(code);
break;
case kStorageOneDriveId:
- storage = new OneDrive::OneDriveStorage(code);
+ new OneDrive::OneDriveStorage(code);
break;
case kStorageGoogleDriveId:
- storage = new GoogleDrive::GoogleDriveStorage(code);
+ new GoogleDrive::GoogleDriveStorage(code);
break;
case kStorageBoxId:
- storage = new Box::BoxStorage(code);
+ new Box::BoxStorage(code);
break;
}
// in these constructors Storages request token using the passed code
// when the token is received, they call replaceStorage()
// or removeStorage(), if some error occurred
// thus, no memory leak happens
-
- // FIXME: storage is set, but never used. Should it be returned from this function for class variable _storages?
}
Networking::Request *CloudManager::listDirectory(Common::String path, Storage::ListDirectoryCallback callback, Networking::ErrorCallback errorCallback, bool recursive) {