Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixing more build warnings #16

Open
wants to merge 6 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions FsprgEmbeddedStore/FsprgEmbeddedStoreController.m
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
#import "FsprgOrderDocumentRepresentation.h"

// We don't retrieve SSL certificates below OSX 10.6
#define RETRIEVE_SSL_CERTIFICATES defined(MAC_OS_X_VERSION_10_6) && MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_6
#define RETRIEVE_SSL_CERTIFICATES /* defined(MAC_OS_X_VERSION_10_6) && */ MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_6

@interface FsprgEmbeddedStoreController ()

Expand Down Expand Up @@ -294,7 +294,7 @@ - (void)webView:(WebView *)sender didFailLoadWithError:(NSError *)error forFrame
- (void)webView:(WebView *)sender runJavaScriptAlertPanelWithMessage:(NSString *)message initiatedByFrame:(WebFrame *)frame
{
NSString *title = [sender mainFrameTitle];
NSAlert *alertPanel = [[NSAlert alloc] init];
NSAlert *alertPanel = [[[NSAlert alloc] init] autorelease];
[alertPanel setMessageText:title];
[alertPanel setInformativeText:message];
#if MAC_OS_X_VERSION_MIN_REQUIRED < MAC_OS_X_VERSION_10_9
Expand Down
6 changes: 6 additions & 0 deletions FsprgEmbeddedStore/FsprgStoreParameters.m
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,10 @@ + (void)initialize
NSStringFromSelector(@selector(orderProcessType)),
NSStringFromSelector(@selector(storeId)),
NSStringFromSelector(@selector(productId)),
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wselector"
NSStringFromSelector(@selector(mode)),
#pragma clang diagnostic pop
NSStringFromSelector(@selector(campaign)),
NSStringFromSelector(@selector(option)),
NSStringFromSelector(@selector(referrer)),
Expand Down Expand Up @@ -144,7 +147,10 @@ - (NSURL *)toURL
[keys removeObject:kOrderProcessType];
[keys removeObject:kStoreId];
[keys removeObject:kProductId];
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wselector"
[keys sortUsingSelector:@selector(compare:)];
#pragma clang diagnostic pop

NSString *queryStr = @"";
NSUInteger i, count = [keys count];
Expand Down
2 changes: 1 addition & 1 deletion FsprgEmbeddedStore/Model/FsprgOrder.m
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,9 @@ @implementation FsprgOrder
+ (FsprgOrder *)orderFromData:(NSData *)aData
{
NSPropertyListFormat *format = nil;
NSString *errorDesc = nil;

#if MAC_OS_X_VERSION_MIN_REQUIRED < MAC_OS_X_VERSION_10_6
NSString *errorDesc = nil;
NSDictionary *aDict = [NSPropertyListSerialization propertyListFromData:aData
mutabilityOption:NSPropertyListImmutable
format:format
Expand Down
2 changes: 1 addition & 1 deletion TestApp/AppController.m
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ - (NSView *)viewWithFrame:(NSRect)frame forOrder:(FsprgOrder *)order
errorDescription:&errorDesc];
NSString *orderAsStr = [[[NSString alloc] initWithData:data encoding:NSUTF8StringEncoding] autorelease];

OrderViewController *orderViewController = [[OrderViewController alloc] initWithNibName:@"OrderView" bundle:nil];
OrderViewController *orderViewController = [[[OrderViewController alloc] initWithNibName:@"OrderView" bundle:nil] autorelease];
[orderViewController setRepresentedObject:orderAsStr];

[[[orderViewController view] window] setBackgroundColor:[NSColor blackColor]];
Expand Down
82 changes: 81 additions & 1 deletion TestApp/TestApp.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -292,7 +292,7 @@
29B97313FDCFA39411CA2CEA /* Project object */ = {
isa = PBXProject;
attributes = {
LastUpgradeCheck = 0440;
LastUpgradeCheck = 0510;
ORGANIZATIONNAME = FastSpring;
};
buildConfigurationList = C01FCF4E08A954540054247B /* Build configuration list for PBXProject "TestApp" */;
Expand Down Expand Up @@ -376,9 +376,49 @@
C01FCF4B08A954540054247B /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
CLANG_ANALYZER_SECURITY_FLOATLOOPCOUNTER = YES;
CLANG_ANALYZER_SECURITY_INSECUREAPI_RAND = YES;
CLANG_ANALYZER_SECURITY_INSECUREAPI_STRCPY = YES;
CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_CXX0X_EXTENSIONS = YES;
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_IMPLICIT_SIGN_CONVERSION = YES;
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_OBJC_EXPLICIT_OWNERSHIP_TYPE = YES;
CLANG_WARN_OBJC_IMPLICIT_ATOMIC_PROPERTIES = YES;
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
CLANG_WARN_OBJC_MISSING_PROPERTY_SYNTHESIS = YES;
CLANG_WARN_OBJC_RECEIVER_WEAK = YES;
CLANG_WARN_OBJC_REPEATED_USE_OF_WEAK = YES;
CLANG_WARN_SUSPICIOUS_IMPLICIT_CONVERSION = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
CLANG_WARN__EXIT_TIME_DESTRUCTORS = YES;
COMBINE_HIDPI_IMAGES = YES;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = TestApp_Prefix.pch;
GCC_TREAT_IMPLICIT_FUNCTION_DECLARATIONS_AS_ERRORS = YES;
GCC_TREAT_INCOMPATIBLE_POINTER_TYPE_WARNINGS_AS_ERRORS = YES;
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
GCC_WARN_ABOUT_MISSING_FIELD_INITIALIZERS = YES;
GCC_WARN_ABOUT_MISSING_NEWLINE = YES;
GCC_WARN_ABOUT_MISSING_PROTOTYPES = YES;
GCC_WARN_HIDDEN_VIRTUAL_FUNCTIONS = YES;
GCC_WARN_INITIALIZER_NOT_FULLY_BRACKETED = YES;
GCC_WARN_MULTIPLE_DEFINITION_TYPES_FOR_SELECTOR = YES;
GCC_WARN_NON_VIRTUAL_DESTRUCTOR = YES;
GCC_WARN_PEDANTIC = YES;
GCC_WARN_SHADOW = YES;
GCC_WARN_SIGN_COMPARE = YES;
GCC_WARN_STRICT_SELECTOR_MATCH = YES;
GCC_WARN_UNDECLARED_SELECTOR = YES;
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNKNOWN_PRAGMAS = YES;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_LABEL = YES;
INFOPLIST_FILE = Info.plist;
PRODUCT_NAME = TestApp;
WRAPPER_EXTENSION = app;
Expand All @@ -388,9 +428,49 @@
C01FCF4C08A954540054247B /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
CLANG_ANALYZER_SECURITY_FLOATLOOPCOUNTER = YES;
CLANG_ANALYZER_SECURITY_INSECUREAPI_RAND = YES;
CLANG_ANALYZER_SECURITY_INSECUREAPI_STRCPY = YES;
CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_CXX0X_EXTENSIONS = YES;
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_IMPLICIT_SIGN_CONVERSION = YES;
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_OBJC_EXPLICIT_OWNERSHIP_TYPE = YES;
CLANG_WARN_OBJC_IMPLICIT_ATOMIC_PROPERTIES = YES;
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
CLANG_WARN_OBJC_MISSING_PROPERTY_SYNTHESIS = YES;
CLANG_WARN_OBJC_RECEIVER_WEAK = YES;
CLANG_WARN_OBJC_REPEATED_USE_OF_WEAK = YES;
CLANG_WARN_SUSPICIOUS_IMPLICIT_CONVERSION = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
CLANG_WARN__EXIT_TIME_DESTRUCTORS = YES;
COMBINE_HIDPI_IMAGES = YES;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = TestApp_Prefix.pch;
GCC_TREAT_IMPLICIT_FUNCTION_DECLARATIONS_AS_ERRORS = YES;
GCC_TREAT_INCOMPATIBLE_POINTER_TYPE_WARNINGS_AS_ERRORS = YES;
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
GCC_WARN_ABOUT_MISSING_FIELD_INITIALIZERS = YES;
GCC_WARN_ABOUT_MISSING_NEWLINE = YES;
GCC_WARN_ABOUT_MISSING_PROTOTYPES = YES;
GCC_WARN_HIDDEN_VIRTUAL_FUNCTIONS = YES;
GCC_WARN_INITIALIZER_NOT_FULLY_BRACKETED = YES;
GCC_WARN_MULTIPLE_DEFINITION_TYPES_FOR_SELECTOR = YES;
GCC_WARN_NON_VIRTUAL_DESTRUCTOR = YES;
GCC_WARN_PEDANTIC = YES;
GCC_WARN_SHADOW = YES;
GCC_WARN_SIGN_COMPARE = YES;
GCC_WARN_STRICT_SELECTOR_MATCH = YES;
GCC_WARN_UNDECLARED_SELECTOR = YES;
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNKNOWN_PRAGMAS = YES;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_LABEL = YES;
INFOPLIST_FILE = Info.plist;
PRODUCT_NAME = TestApp;
WRAPPER_EXTENSION = app;
Expand Down