wasStitchNET

Subversion Repositories:
Compare Path: Rev
With Path: Rev
?path1? @ 16  →  ?path2? @ 17
/Constants.cs
@@ -27,7 +27,7 @@
public const string GEOIP_CITY_DATABASE = @"GeoLite2-City.mmdb.gz";
public const string GEOIP_UNKNOWN_COUNTRY = @"a galaxy far, far away...";
 
public const string OFFICIAL_UPDATE_SERVER = @"http://corrade.grimore.org";
public const string OFFICIAL_UPDATE_SERVER = @"https://corrade.grimore.org";
 
public const string SERVICE_NAME = @"Stitch";
public const string SERVICE_DESCRIPTION = @"The Stitch Software Update Service.";
/Repository/Hashing.cs
@@ -4,6 +4,7 @@
// rights of fair usage, the disclaimer and warranty conditions. //
///////////////////////////////////////////////////////////////////////////
 
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Net;
@@ -10,6 +11,7 @@
using System.Security.Cryptography;
using System.Threading.Tasks;
using wasDAVClient;
using wasDAVClient.Model;
using wasSharp;
using wasSharpNET.IO.Utilities;
 
@@ -32,11 +34,8 @@
foreach (var stream in Directory
.GetFiles(path, "*.*", SearchOption.AllDirectories)
.OrderBy(o => o.Split(Path.DirectorySeparatorChar).Last())
.AsParallel()
.AsOrdered()
.Select(file => IOExtensions.GetWriteStream(file, FileMode.Open,
FileAccess.Read, FileShare.Read, STITCH_CONSTANTS.LOCAL_FILE_ACCESS_TIMEOUT))
.AsSequential())
FileAccess.Read, FileShare.Read, STITCH_CONSTANTS.LOCAL_FILE_ACCESS_TIMEOUT)))
using (var binaryReader = new BinaryReader(stream))
{
var buff = new byte[bufferSize];
@@ -85,13 +84,11 @@
{
using (var sha1managed = new SHA1Managed())
{
//var list = new List<Item>();
foreach (var stream in (await client.List(path, Constants.DavDepth.ALL))
.OrderBy(o => o.DisplayName)
.Where(item => !item.IsCollection)
.AsParallel()
.AsOrdered()
.Select(file => client.Download(file.Href))
.AsSequential())
.Select(file => client.Download(file.Href)))
using (var binaryReader = new BinaryReader(await stream))
{
var buff = new byte[bufferSize];