mirror of
https://github.com/sparkle-project/Sparkle
synced 2026-11-26 04:57:54 +00:00
Fix warnings and binary compatibility issues that crop up when building the BinaryDelta tool against different SDKs.
This commit is contained in:
1 parent
3ef4c09f71
commit
3ff2d82ecf
3 files changed
+7
-2
No files matched your search
@@ -3,3 +3,6 @@
|
||||
PRODUCT_NAME = BinaryDelta
|
||||
GCC_PREFIX_HEADER =
|
||||
SDKROOT = macosx10.6
|
||||
MACOSX_DEPLOYMENT_TARGET[arch=i386] = 10.6
|
||||
MACOSX_DEPLOYMENT_TARGET[arch=x86_64] = 10.6
|
||||
MACOSX_DEPLOYMENT_TARGET[arch=ppc] = 10.6
|
||||
@@ -68,7 +68,7 @@ static void _hashOfFile(unsigned char* hash, FTSENT *ent)
|
||||
return;
|
||||
}
|
||||
|
||||
size_t fileSize = ent->fts_statp->st_size;
|
||||
size_t fileSize = (size_t)ent->fts_statp->st_size;
|
||||
void *buffer = mmap(0, fileSize, PROT_READ, MAP_FILE | MAP_PRIVATE, fileDescriptor, 0);
|
||||
if (buffer == (void*)-1) {
|
||||
close(fileDescriptor);
|
||||
|
||||
+3
-1
@@ -6,6 +6,8 @@
|
||||
// Copyright 2009 Mark Rowe. All rights reserved.
|
||||
//
|
||||
|
||||
#define _DARWIN_NO_64_BIT_INODE 1
|
||||
|
||||
#include "SUBinaryDeltaCommon.h"
|
||||
#include "SUBinaryDeltaApply.h"
|
||||
#include <CommonCrypto/CommonDigest.h>
|
||||
@@ -75,7 +77,7 @@ static NSString *temporaryPatchFile(NSString *patchFile)
|
||||
|
||||
static BOOL shouldSkipDeltaCompression(NSString *key, NSDictionary* originalInfo, NSDictionary *newInfo)
|
||||
{
|
||||
size_t fileSize = [[newInfo objectForKey:@"size"] unsignedLongLongValue];
|
||||
unsigned long long fileSize = [[newInfo objectForKey:@"size"] unsignedLongLongValue];
|
||||
if (fileSize < 4096)
|
||||
return YES;
|
||||
|
||||
|
||||
Reference in new issue
Block a user