mirror of
https://github.com/velopack/velopack.git
synced 2025-10-25 15:19:22 +00:00
Clean up some compiler warnings
This commit is contained in:
@@ -52,7 +52,6 @@ bool hasEnding(std::wstring const& fullString, std::wstring const& ending)
|
||||
void unzipSingleFile(BYTE* zipBuf, DWORD cZipBuf, wstring fileLocation, std::function<bool(ZIPENTRY&)>& 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;
|
||||
|
||||
@@ -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
|
||||
|
||||
@@ -12,6 +12,7 @@
|
||||
<PublishTrimmed>true</PublishTrimmed>
|
||||
<BuiltInComInteropSupport>true</BuiltInComInteropSupport>
|
||||
<EnableCompressionInSingleFile>true</EnableCompressionInSingleFile>
|
||||
<SuppressTrimAnalysisWarnings>true</SuppressTrimAnalysisWarnings>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
|
||||
@@ -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);
|
||||
}
|
||||
|
||||
@@ -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);
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
<BuiltInComInteropSupport>true</BuiltInComInteropSupport>
|
||||
<EnableCompressionInSingleFile>true</EnableCompressionInSingleFile>
|
||||
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
|
||||
<SuppressTrimAnalysisWarnings>true</SuppressTrimAnalysisWarnings>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
<Title>Squirrel.Tests</Title>
|
||||
<IsPackable>false</IsPackable>
|
||||
<IsTest>true</IsTest>
|
||||
<NoWarn>CS1998</NoWarn>
|
||||
<NoWarn>CS1998,xUnit2015,xUnit2017,xUnit2005,xUnit2009,xUnit2013,xUnit2004</NoWarn>
|
||||
<SignAssembly>True</SignAssembly>
|
||||
<AssemblyOriginatorKeyFile>..\Squirrel.snk</AssemblyOriginatorKeyFile>
|
||||
</PropertyGroup>
|
||||
|
||||
Reference in New Issue
Block a user