Fix errors and suppress warnings due to use of LLVM.
if ([inputStream streamStatus] == NSStreamEventErrorOccurred) {
[compressor closeStream];
if (err) {
- *err = [NSError errorWithDomain:NetworkRequestErrorDomain code:ASICompressionError userInfo:[NSDictionary dictionaryWithObjectsAndKeys:[NSString stringWithFormat:@"Compression of %@ failed because we were unable to write to the destination data file at &@",sourcePath,destinationPath],NSLocalizedDescriptionKey,[outputStream streamError],NSUnderlyingErrorKey,nil]];
+ *err = [NSError errorWithDomain:NetworkRequestErrorDomain code:ASICompressionError userInfo:[NSDictionary dictionaryWithObjectsAndKeys:[NSString stringWithFormat:@"Compression of %@ failed because we were unable to write to the destination data file at %@",sourcePath,destinationPath],NSLocalizedDescriptionKey,[outputStream streamError],NSUnderlyingErrorKey,nil]];
}
return NO;
}
+ (NSError *)deflateErrorWithCode:(int)code
{
- return [NSError errorWithDomain:NetworkRequestErrorDomain code:ASICompressionError userInfo:[NSDictionary dictionaryWithObjectsAndKeys:[NSString stringWithFormat:@"Compression of data failed with code %hi",code],NSLocalizedDescriptionKey,nil]];
+ return [NSError errorWithDomain:NetworkRequestErrorDomain code:ASICompressionError userInfo:[NSDictionary dictionaryWithObjectsAndKeys:[NSString stringWithFormat:@"Compression of data failed with code %i",code],NSLocalizedDescriptionKey,nil]];
}
@synthesize streamReady;
if ([inputStream streamStatus] == NSStreamEventErrorOccurred) {
[decompressor closeStream];
if (err) {
- *err = [NSError errorWithDomain:NetworkRequestErrorDomain code:ASICompressionError userInfo:[NSDictionary dictionaryWithObjectsAndKeys:[NSString stringWithFormat:@"Decompression of %@ failed because we were unable to write to the destination data file at &@",sourcePath,destinationPath],NSLocalizedDescriptionKey,[outputStream streamError],NSUnderlyingErrorKey,nil]];
+ *err = [NSError errorWithDomain:NetworkRequestErrorDomain code:ASICompressionError userInfo:[NSDictionary dictionaryWithObjectsAndKeys:[NSString stringWithFormat:@"Decompression of %@ failed because we were unable to write to the destination data file at %@",sourcePath,destinationPath],NSLocalizedDescriptionKey,[outputStream streamError],NSUnderlyingErrorKey,nil]];
}
return NO;
}
+ (NSError *)inflateErrorWithCode:(int)code
{
- return [NSError errorWithDomain:NetworkRequestErrorDomain code:ASICompressionError userInfo:[NSDictionary dictionaryWithObjectsAndKeys:[NSString stringWithFormat:@"Decompression of data failed with code %hi",code],NSLocalizedDescriptionKey,nil]];
+ return [NSError errorWithDomain:NetworkRequestErrorDomain code:ASICompressionError userInfo:[NSDictionary dictionaryWithObjectsAndKeys:[NSString stringWithFormat:@"Decompression of data failed with code %i",code],NSLocalizedDescriptionKey,nil]];
}
@synthesize streamReady;
NSError *err = nil;
[self setPostLength:[[[NSFileManager defaultManager] attributesOfItemAtPath:path error:&err] fileSize]];
if (err) {
- [self failWithError:[NSError errorWithDomain:NetworkRequestErrorDomain code:ASIFileManagementError userInfo:[NSDictionary dictionaryWithObjectsAndKeys:[NSString stringWithFormat:@"Failed to get attributes for file at path '@%'",path],NSLocalizedDescriptionKey,error,NSUnderlyingErrorKey,nil]]];
+ [self failWithError:[NSError errorWithDomain:NetworkRequestErrorDomain code:ASIFileManagementError userInfo:[NSDictionary dictionaryWithObjectsAndKeys:[NSString stringWithFormat:@"Failed to get attributes for file at path '%@'",path],NSLocalizedDescriptionKey,error,NSUnderlyingErrorKey,nil]]];
return;
}
NSError *err = nil;
[self setPartialDownloadSize:[[[NSFileManager defaultManager] attributesOfItemAtPath:[self temporaryFileDownloadPath] error:&err] fileSize]];
if (err) {
- [self failWithError:[NSError errorWithDomain:NetworkRequestErrorDomain code:ASIFileManagementError userInfo:[NSDictionary dictionaryWithObjectsAndKeys:[NSString stringWithFormat:@"Failed to get attributes for file at path '@%'",[self temporaryFileDownloadPath]],NSLocalizedDescriptionKey,error,NSUnderlyingErrorKey,nil]]];
+ [self failWithError:[NSError errorWithDomain:NetworkRequestErrorDomain code:ASIFileManagementError userInfo:[NSDictionary dictionaryWithObjectsAndKeys:[NSString stringWithFormat:@"Failed to get attributes for file at path '%@'",[self temporaryFileDownloadPath]],NSLocalizedDescriptionKey,error,NSUnderlyingErrorKey,nil]]];
return;
}
}
#pragma mark - Notification
- (NSString *)notificationName:(NSString *)key identifier:(NSString *)identifier {
- return [NSString stringWithFormat:@"%@-%@-%i", key, self.account.uuid, identifier];
+ return [NSString stringWithFormat:@"%@-%@-%@", key, self.account.uuid, identifier];
}
- (void)requestFinished:(OpenStackRequest *)request {
- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section
{
- if (section == kOverview)
+ if (section == kOverview) {
return 2;
- else if (section == kPermissions) {
- if (account.sharingAccount)
+ } else if (section == kPermissions) {
+ if (account.sharingAccount) {
return [permissions count];
- else
+ } else {
return 1 + [permissions count];
- }
- else if (section == kMetadata)
- if (folderIsReadOnly)
+ }
+ } else if (section == kMetadata) {
+ if (folderIsReadOnly) {
return [folder.metadata count];
- else
- return 1 + [folder.metadata count];
- return 0;
+ } else {
+ return 1 + [folder.metadata count];
+ }
+ }
+ return 0;
}
- (CGFloat)findLabelHeight:(NSString*)text font:(UIFont *)font {
[addDict setObject:data forKey:(id)kSecValueData];
res = SecItemAdd((CFDictionaryRef)addDict, NULL);
- NSAssert1(res == errSecSuccess, @"Recieved %d from SecItemAdd!", res);
+ NSAssert1(res == errSecSuccess, @"Recieved %ld from SecItemAdd!", res);
}
} else if (res == errSecSuccess) {
// Modify an existing one
NSDictionary *attributeDict = [NSDictionary dictionaryWithObject:data forKey:(id)kSecValueData];
res = SecItemUpdate((CFDictionaryRef)existsQueryDictionary, (CFDictionaryRef)attributeDict);
- NSAssert1(res == errSecSuccess, @"SecItemUpdated returned %d!", res);
+ NSAssert1(res == errSecSuccess, @"SecItemUpdated returned %ld!", res);
} else {
- NSAssert1(NO, @"Received %d from SecItemCopyMatching!", res);
+ NSAssert1(NO, @"Received %ld from SecItemCopyMatching!", res);
}
return YES;
NSString *string = [[[NSString alloc] initWithData:data encoding:NSUTF8StringEncoding] autorelease];
return string;
} else {
- NSAssert1(res == errSecItemNotFound, @"SecItemCopyMatching returned %d!", res);
+ NSAssert1(res == errSecItemNotFound, @"SecItemCopyMatching returned %ld!", res);
}
return nil;
// exception file name
NSString *directory = HTNoticesDirectory();
- NSString *fileName = [NSString stringWithFormat:@"%d", time(NULL)];
+ NSString *fileName = [NSString stringWithFormat:@"%ld", time(NULL)];
value = [directory stringByAppendingPathComponent:fileName];
value = [value stringByAppendingPathExtension:HTNoticePathExtension];
value_str = [value UTF8String];
static NSString *HTNotifierHostName = @"hoptoadapp.com";
#define HTNotifierURL [NSURL URLWithString: \
[NSString stringWithFormat: \
- @"%@://%@%/notifier_api/v2/notices", \
+ @"%@://%@/notifier_api/v2/notices", \
(self.useSSL) ? @"https" : @"http", \
HTNotifierHostName]]
#define HTIsMultitaskingSupported \
28C286E10D94DF7D0034E888 /* RootViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 28C286E00D94DF7D0034E888 /* RootViewController.m */; };
28F335F11007B36200424DE2 /* RootViewController.xib in Resources */ = {isa = PBXBuildFile; fileRef = 28F335F01007B36200424DE2 /* RootViewController.xib */; };
376B22B414975DAD00007386 /* LBAlgorithmAnimationViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 27265A1A1397EAE5000617C0 /* LBAlgorithmAnimationViewController.m */; };
+ 613471611634369E0036373B /* HTNotifier.m in Sources */ = {isa = PBXBuildFile; fileRef = 7F8F371013859EDA0034710B /* HTNotifier.m */; };
+ 613471621634369F0036373B /* HTNotifier.m in Sources */ = {isa = PBXBuildFile; fileRef = 7F8F371013859EDA0034710B /* HTNotifier.m */; };
6142B27B1523601E00A1BFAD /* pithos_icon_iPad.png in Resources */ = {isa = PBXBuildFile; fileRef = 6142B27A1523601E00A1BFAD /* pithos_icon_iPad.png */; };
6142B27D1523602300A1BFAD /* pithos_icon_iPad@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 6142B27C1523602300A1BFAD /* pithos_icon_iPad@2x.png */; };
61DEA8F714904BC000E0D3AD /* pithos_icon.png in Resources */ = {isa = PBXBuildFile; fileRef = 61DEA8F514904BC000E0D3AD /* pithos_icon.png */; };
7F8F372A13859EDA0034710B /* HTFunctions.m in Sources */ = {isa = PBXBuildFile; fileRef = 7F8F370C13859EDA0034710B /* HTFunctions.m */; };
7F8F372B13859EDA0034710B /* HTNotice.m in Sources */ = {isa = PBXBuildFile; fileRef = 7F8F370E13859EDA0034710B /* HTNotice.m */; };
7F8F372D13859EDA0034710B /* HTNotice.m in Sources */ = {isa = PBXBuildFile; fileRef = 7F8F370E13859EDA0034710B /* HTNotice.m */; };
- 7F8F372E13859EDA0034710B /* HTNotifier.m in Sources */ = {isa = PBXBuildFile; fileRef = 7F8F371013859EDA0034710B /* HTNotifier.m */; };
- 7F8F373013859EDA0034710B /* HTNotifier.m in Sources */ = {isa = PBXBuildFile; fileRef = 7F8F371013859EDA0034710B /* HTNotifier.m */; };
7F8F373113859EDA0034710B /* HTNotifier_iOS.m in Sources */ = {isa = PBXBuildFile; fileRef = 7F8F371213859EDA0034710B /* HTNotifier_iOS.m */; };
7F8F373313859EDA0034710B /* HTNotifier_iOS.m in Sources */ = {isa = PBXBuildFile; fileRef = 7F8F371213859EDA0034710B /* HTNotifier_iOS.m */; };
7F8F373413859EDA0034710B /* HTNotifier_Mac.m in Sources */ = {isa = PBXBuildFile; fileRef = 7F8F371413859EDA0034710B /* HTNotifier_Mac.m */; };
1D30AB110D05D00D00671497 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; };
1D3623240D0F684500981E51 /* OpenStackAppDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = OpenStackAppDelegate.h; sourceTree = "<group>"; };
1D3623250D0F684500981E51 /* OpenStackAppDelegate.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = OpenStackAppDelegate.m; sourceTree = "<group>"; };
- 1D6058910D05DD3D006BFB54 /* Pithos+.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = "Pithos+.app"; sourceTree = BUILT_PRODUCTS_DIR; };
+ 1D6058910D05DD3D006BFB54 /* Pithos+.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; name = "Pithos+.app"; path = Pithos.app; sourceTree = BUILT_PRODUCTS_DIR; };
24332D521472839300063C8B /* myShared.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = myShared.png; sourceTree = "<group>"; };
24332D551472839A00063C8B /* othersShared.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = othersShared.png; sourceTree = "<group>"; };
24332D571472A35000063C8B /* SharingAccountsViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SharingAccountsViewController.h; sourceTree = "<group>"; };
7F9351B4138457D80097720F /* Analytics.m in Sources */,
7F8F372813859EDA0034710B /* HTFunctions.m in Sources */,
7F8F372B13859EDA0034710B /* HTNotice.m in Sources */,
- 7F8F372E13859EDA0034710B /* HTNotifier.m in Sources */,
7F8F373113859EDA0034710B /* HTNotifier_iOS.m in Sources */,
7F8F373413859EDA0034710B /* HTNotifier_Mac.m in Sources */,
7F8F373713859EDA0034710B /* DDXMLDocument.m in Sources */,
24C9DE5B1484E3E9001F4DB9 /* PithosUtilities.m in Sources */,
376B22B414975DAD00007386 /* LBAlgorithmAnimationViewController.m in Sources */,
249F004C14BC836A000AB729 /* ObjectVersionsViewController.m in Sources */,
+ 613471621634369F0036373B /* HTNotifier.m in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
7F9351B5138457D80097720F /* Analytics.m in Sources */,
7F8F372A13859EDA0034710B /* HTFunctions.m in Sources */,
7F8F372D13859EDA0034710B /* HTNotice.m in Sources */,
- 7F8F373013859EDA0034710B /* HTNotifier.m in Sources */,
7F8F373313859EDA0034710B /* HTNotifier_iOS.m in Sources */,
7F8F373613859EDA0034710B /* HTNotifier_Mac.m in Sources */,
7F8F373913859EDA0034710B /* DDXMLDocument.m in Sources */,
2726C64F13B28D1000BC7330 /* ConfigureLoadBalancerViewController.m in Sources */,
27DADC1713B94D6C00F9E906 /* LBNodeViewController.m in Sources */,
27DC5DDA13CB925200091902 /* LoadBalancerConnectionThrottle.m in Sources */,
+ 613471611634369E0036373B /* HTNotifier.m in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};