Skip to content

Commit

Permalink
updat ios
Browse files Browse the repository at this point in the history
  • Loading branch information
brucenan committed Jul 26, 2016
1 parent 3ee97fd commit 0426fb3
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 18 deletions.
Binary file not shown.
2 changes: 1 addition & 1 deletion sdk/iOS_sdk/UMSAgent/Global.m
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ + (int)getConfigParams:(NSString*)key
}
else if([key isEqualToString:@"fileSize"])
{
return DEFAULT_FILE_SIZE ;
return DEFAULT_FILE_SIZE;
}
}
return 0;
Expand Down
27 changes: 14 additions & 13 deletions sdk/iOS_sdk/UMSAgent/UMSAgent/UMSAgent.m
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
#import <sys/utsname.h>
#import "ClientData.h"
#import "Tag.h"
#import <AdSupport/AdSupport.h>
//#import <AdSupport/AdSupport.h>
#import "SFHFKeychainUtils.h"
#import "ErrorDao.h"
#import "UsingLogDao.h"
Expand Down Expand Up @@ -1395,18 +1395,19 @@ + (NSString *)getUMSUDID
[SFHFKeychainUtils storeUsername:@"UMSAgentUDID" andPassword:macAddress forServiceName:@"UMSAgent" updateExisting:NO error:nil];
return macAddress;
} else {
NSString *idfa = [[[ASIdentifierManager sharedManager] advertisingIdentifier] UUIDString];
if(idfa && ![idfa isEqualToString:@""])
{
[SFHFKeychainUtils storeUsername:@"UMSAgentUDID" andPassword:idfa forServiceName:@"UMSAgent" updateExisting:NO error:nil];
return idfa;
}
else
{
NSString *openUDID = [UMS_OpenUDID value];
[SFHFKeychainUtils storeUsername:@"UMSAgentUDID" andPassword:openUDID forServiceName:@"UMSAgent" updateExisting:NO error:nil];
return openUDID;
}
//注释ASIdentifierManager,去除AdSupport.framework
// NSString *idfa = [[[ASIdentifierManager sharedManager] advertisingIdentifier] UUIDString];
// if(idfa && ![idfa isEqualToString:@""])
// {
// [SFHFKeychainUtils storeUsername:@"UMSAgentUDID" andPassword:idfa forServiceName:@"UMSAgent" updateExisting:NO error:nil];
// return idfa;
// }
// else
// {
NSString *openUDID = [UMS_OpenUDID value];
[SFHFKeychainUtils storeUsername:@"UMSAgentUDID" andPassword:openUDID forServiceName:@"UMSAgent" updateExisting:NO error:nil];
return openUDID;
//}
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@
3609A5D615180C7300BEDA05 /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 3609A5D415180C7300BEDA05 /* InfoPlist.strings */; };
3609A5D915180C7300BEDA05 /* UMSAgentExampleTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 3609A5D815180C7300BEDA05 /* UMSAgentExampleTests.m */; };
3628957017F53986009EE341 /* Security.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 3628956F17F53986009EE341 /* Security.framework */; };
3656570817F41DD50057FA57 /* AdSupport.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 3656570717F41DD50057FA57 /* AdSupport.framework */; };
36B3015D162AF22D0098FEF5 /* SecondViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 36B3015B162AF22D0098FEF5 /* SecondViewController.m */; };
36B3015E162AF22D0098FEF5 /* SecondViewController.xib in Resources */ = {isa = PBXBuildFile; fileRef = 36B3015C162AF22D0098FEF5 /* SecondViewController.xib */; };
36B8E537151C51B5004C3C1F /* CoreTelephony.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 36B8E536151C51B5004C3C1F /* CoreTelephony.framework */; settings = {ATTRIBUTES = (Weak, ); }; };
Expand Down Expand Up @@ -150,7 +149,6 @@
3609A5D715180C7300BEDA05 /* UMSAgentExampleTests.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = UMSAgentExampleTests.h; sourceTree = "<group>"; };
3609A5D815180C7300BEDA05 /* UMSAgentExampleTests.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = UMSAgentExampleTests.m; sourceTree = "<group>"; };
3628956F17F53986009EE341 /* Security.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Security.framework; path = System/Library/Frameworks/Security.framework; sourceTree = SDKROOT; };
3656570717F41DD50057FA57 /* AdSupport.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AdSupport.framework; path = System/Library/Frameworks/AdSupport.framework; sourceTree = SDKROOT; };
36B3015A162AF22D0098FEF5 /* SecondViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SecondViewController.h; sourceTree = "<group>"; };
36B3015B162AF22D0098FEF5 /* SecondViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SecondViewController.m; sourceTree = "<group>"; };
36B3015C162AF22D0098FEF5 /* SecondViewController.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = SecondViewController.xib; sourceTree = "<group>"; };
Expand Down Expand Up @@ -510,7 +508,6 @@
files = (
3628957017F53986009EE341 /* Security.framework in Frameworks */,
E016ACD91B450B89008B07CF /* libUMSAgent.a in Frameworks */,
3656570817F41DD50057FA57 /* AdSupport.framework in Frameworks */,
36B8E537151C51B5004C3C1F /* CoreTelephony.framework in Frameworks */,
3609A5AE15180C7300BEDA05 /* UIKit.framework in Frameworks */,
3609A5B015180C7300BEDA05 /* Foundation.framework in Frameworks */,
Expand Down Expand Up @@ -564,7 +561,6 @@
children = (
E0D7106F1B44CCDD00401A9A /* KSCrash */,
3628956F17F53986009EE341 /* Security.framework */,
3656570717F41DD50057FA57 /* AdSupport.framework */,
36B8E536151C51B5004C3C1F /* CoreTelephony.framework */,
3609A5AD15180C7300BEDA05 /* UIKit.framework */,
3609A5AF15180C7300BEDA05 /* Foundation.framework */,
Expand Down

0 comments on commit 0426fb3

Please sign in to comment.