Revision 2b0ec5b8 trunk/Pithos.Core/Agents/Downloader.cs

b/trunk/Pithos.Core/Agents/Downloader.cs
168 168
            //Calculate the file's treehash
169 169

  
170 170
            //TODO: Should pass cancellation token here
171
            var treeHash = await Signature.CalculateTreeHashAsync(localPath, serverHash.BlockSize, serverHash.BlockHash, 2);
171
            var treeHash = await Signature.CalculateTreeHashAsync(localPath, (int)serverHash.BlockSize, serverHash.BlockHash, 2);
172 172

  
173 173
            //And compare it with the server's hash
174 174
            var upHashes = serverHash.GetHashesAsStrings();
175 175
            var localHashes = treeHash.HashDictionary;
176 176
            ReportDownloadProgress(Path.GetFileName(localPath), 0, upHashes.Length, cloudFile.Bytes);
177
            for (int i = 0; i < upHashes.Length; i++)
177
            for (var i = 0; i < upHashes.Length; i++)
178 178
            {
179 179
                if (await WaitOrAbort(cloudFile, cancellationToken))
180 180
                    return;

Also available in: Unified diff