Skip to content

Commit

Permalink
[Dynamic Links] Address Xcode 14.3 Analyzer issues (#11243)
Browse files Browse the repository at this point in the history
  • Loading branch information
ncooke3 committed May 8, 2023
1 parent a553a4d commit 7453895
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion FirebaseDynamicLinks/Sources/FIRDLJavaScriptExecutor.m
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@ - (void)webView:(WKWebView *)webView
// From:
// https://developer.apple.com/documentation/apple-silicon/about-the-rosetta-translation-environment
#if TARGET_OS_SIMULATOR
static int processIsTranslated() {
static int processIsTranslated(void) {
int ret = 0;
size_t size = sizeof(ret);
if (sysctlbyname("sysctl.proc_translated", &ret, &size, NULL, 0) == -1) {
Expand Down
10 changes: 5 additions & 5 deletions FirebaseDynamicLinks/Sources/Utilities/FDLUtilities.m
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,7 @@ BOOL FIRDLOSVersionSupported(NSString *_Nullable systemVersion, NSString *minSup
return [systemVersion compare:minSupportedVersion options:NSNumericSearch] != NSOrderedAscending;
}

NSDate *_Nullable FIRDLAppInstallationDate() {
NSDate *_Nullable FIRDLAppInstallationDate(void) {
NSURL *documentsDirectoryURL =
[[[NSFileManager defaultManager] URLsForDirectory:NSApplicationSupportDirectory
inDomains:NSUserDomainMask] firstObject];
Expand All @@ -178,7 +178,7 @@ BOOL FIRDLOSVersionSupported(NSString *_Nullable systemVersion, NSString *minSup
return nil;
}

NSString *FIRDLDeviceModelName() {
NSString *FIRDLDeviceModelName(void) {
// this method will return string like iPad3,3
// for Simulator this will be x86_64
static NSString *machineString = @"";
Expand All @@ -199,17 +199,17 @@ BOOL FIRDLOSVersionSupported(NSString *_Nullable systemVersion, NSString *minSup
return machineString;
}

NSString *FIRDLDeviceLocale() {
NSString *FIRDLDeviceLocale(void) {
// expected return value from this method looks like: @"en-US"
return [[[NSLocale currentLocale] localeIdentifier] stringByReplacingOccurrencesOfString:@"_"
withString:@"-"];
}

NSString *FIRDLDeviceLocaleRaw() {
NSString *FIRDLDeviceLocaleRaw(void) {
return [[NSLocale currentLocale] localeIdentifier];
}

NSString *FIRDLDeviceTimezone() {
NSString *FIRDLDeviceTimezone(void) {
NSString *timeZoneName = [[NSTimeZone localTimeZone] name];
return timeZoneName;
}
Expand Down

0 comments on commit 7453895

Please sign in to comment.