Fixing loads of msvc warnings (mainly size_t vs int issues).
This commit is contained in:
@@ -59,9 +59,9 @@ public:
|
||||
bool GetHashForAvatar(const std::string &fileName, MD5Buf &md5buf) const;
|
||||
bool GetAvatarFileName(const MD5Buf &md5buf, std::string &fileName) const;
|
||||
bool HasAvatar(const MD5Buf &md5buf) const;
|
||||
bool StoreAvatarInCache(const MD5Buf &md5buf, AvatarFileType avatarFileType, const unsigned char *data, unsigned size, bool upload);
|
||||
bool StoreAvatarInCache(const MD5Buf &md5buf, AvatarFileType avatarFileType, const unsigned char *data, size_t size, bool upload);
|
||||
|
||||
static bool IsValidAvatarFileType(AvatarFileType avatarFileType, const unsigned char *fileHeader, unsigned fileHeaderSize);
|
||||
static bool IsValidAvatarFileType(AvatarFileType avatarFileType, const unsigned char *fileHeader, size_t fileHeaderSize);
|
||||
|
||||
void RemoveOldAvatarCacheEntries();
|
||||
|
||||
|
||||
@@ -341,7 +341,7 @@ AvatarManager::HasAvatar(const MD5Buf &md5buf) const
|
||||
}
|
||||
|
||||
bool
|
||||
AvatarManager::StoreAvatarInCache(const MD5Buf &md5buf, AvatarFileType avatarFileType, const unsigned char *data, unsigned size, bool upload)
|
||||
AvatarManager::StoreAvatarInCache(const MD5Buf &md5buf, AvatarFileType avatarFileType, const unsigned char *data, size_t size, bool upload)
|
||||
{
|
||||
bool retVal = false;
|
||||
string cacheDir;
|
||||
@@ -380,7 +380,7 @@ AvatarManager::StoreAvatarInCache(const MD5Buf &md5buf, AvatarFileType avatarFil
|
||||
}
|
||||
|
||||
bool
|
||||
AvatarManager::IsValidAvatarFileType(AvatarFileType avatarFileType, const unsigned char *fileHeader, unsigned fileHeaderSize)
|
||||
AvatarManager::IsValidAvatarFileType(AvatarFileType avatarFileType, const unsigned char *fileHeader, size_t fileHeaderSize)
|
||||
{
|
||||
bool validType = false;
|
||||
|
||||
|
||||
@@ -166,7 +166,7 @@ CryptHelper::MD5Sum(const std::string &fileName, MD5Buf &buf)
|
||||
if (file) {
|
||||
// Calculate MD5 sum of file.
|
||||
unsigned char *readBuf = new unsigned char[8192];
|
||||
int numBytes;
|
||||
size_t numBytes;
|
||||
|
||||
#ifdef HAVE_OPENSSL
|
||||
MD5_CTX context;
|
||||
|
||||
Reference in New Issue
Block a user