diff --git a/src/Setup/Setup.cpp b/src/Setup/Setup.cpp index 4437d2f3..f6b6817d 100644 --- a/src/Setup/Setup.cpp +++ b/src/Setup/Setup.cpp @@ -52,7 +52,6 @@ bool hasEnding(std::wstring const& fullString, std::wstring const& ending) void unzipSingleFile(BYTE* zipBuf, DWORD cZipBuf, wstring fileLocation, std::function& predicate) { HZIP zipFile = OpenZip(zipBuf, cZipBuf, NULL); - //SetUnzipBaseDir(zipFile, targetDir); bool unzipSuccess = false; @@ -60,8 +59,6 @@ void unzipSingleFile(BYTE* zipBuf, DWORD cZipBuf, wstring fileLocation, std::fun int index = 0; do { ZIPENTRY zentry; - wchar_t targetFile[MAX_PATH]; - zr = GetZipItem(zipFile, index, &zentry); if (zr != ZR_OK && zr != ZR_MORE) { break; diff --git a/src/Setup/unzip.cpp b/src/Setup/unzip.cpp index 9994da49..54f5e8d2 100644 --- a/src/Setup/unzip.cpp +++ b/src/Setup/unzip.cpp @@ -1650,16 +1650,16 @@ uInt* v) // working area: values in order of bit length uInt f; // i repeats in table every f entries int g; // maximum code length int h; // table level - register uInt i; // counter, current code - register uInt j; // counter - register int k; // number of bits in current code + /*register*/ uInt i; // counter, current code + /*register*/ uInt j; // counter + /*register*/ int k; // number of bits in current code int l; // bits per table (returned in m) uInt mask; // (1 << w) - 1, to avoid cc -O bug on HP - register uInt* p; // pointer into c[], b[], or v[] + /*register*/ uInt* p; // pointer into c[], b[], or v[] inflate_huft* q; // points to current table struct inflate_huft_s r; // table entry for structure assignment inflate_huft* u[BMAX]; // table stack - register int w; // bits before this table == (l * h) + /*register*/ int w; // bits before this table == (l * h) uInt x[BMAX + 1]; // bit offsets, then code stack uInt* xp; // pointer into x int y; // number of dummy codes added diff --git a/src/SquirrelCli/SquirrelCli.csproj b/src/SquirrelCli/SquirrelCli.csproj index 034c5bd5..3d0fbeaa 100644 --- a/src/SquirrelCli/SquirrelCli.csproj +++ b/src/SquirrelCli/SquirrelCli.csproj @@ -12,6 +12,7 @@ true true true + true diff --git a/src/SquirrelCli/Sync/BackblazeRepository.cs b/src/SquirrelCli/Sync/BackblazeRepository.cs index 5af280f2..bfce7a99 100644 --- a/src/SquirrelCli/Sync/BackblazeRepository.cs +++ b/src/SquirrelCli/Sync/BackblazeRepository.cs @@ -148,7 +148,7 @@ namespace SquirrelCli.Sources private static string GetSHA1Checksum(byte[] bytes) { - var sha = new System.Security.Cryptography.SHA1Managed(); + var sha = System.Security.Cryptography.SHA1.Create(); byte[] checksum = sha.ComputeHash(bytes); return BitConverter.ToString(checksum).Replace("-", String.Empty); } diff --git a/src/StubExecutable/StubExecutable.cpp b/src/StubExecutable/StubExecutable.cpp index 35d838f5..a0042646 100644 --- a/src/StubExecutable/StubExecutable.cpp +++ b/src/StubExecutable/StubExecutable.cpp @@ -61,6 +61,8 @@ std::wstring FindLatestAppDir() continue; } + +#pragma warning( disable : 4244 ) // warning - conversion from 'wchar_t' to 'const _Elem', possible loss of data std::string s(appVer.begin(), appVer.end()); version::Semver200_version thisVer(s); diff --git a/src/Update/Update.csproj b/src/Update/Update.csproj index d0001288..a1fa4bf8 100644 --- a/src/Update/Update.csproj +++ b/src/Update/Update.csproj @@ -11,6 +11,7 @@ true true true + true diff --git a/test/Squirrel.Tests.csproj b/test/Squirrel.Tests.csproj index d9480263..50f8d1fb 100644 --- a/test/Squirrel.Tests.csproj +++ b/test/Squirrel.Tests.csproj @@ -7,7 +7,7 @@ Squirrel.Tests false true - CS1998 + CS1998,xUnit2015,xUnit2017,xUnit2005,xUnit2009,xUnit2013,xUnit2004 True ..\Squirrel.snk