We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents ae27e1e + f0ecc29 commit 8d68c89Copy full SHA for 8d68c89
CoreFoundation/NumberDate.subproj/CFTimeZone.c
@@ -865,7 +865,8 @@ static CFTimeZoneRef __CFTimeZoneCreateSystem(void) {
865
#if !TARGET_OS_ANDROID
866
if (!__tzZoneInfo) __InitTZStrings();
867
ret = readlink(TZDEFAULT, linkbuf, sizeof(linkbuf));
868
- if (__tzZoneInfo && (0 < ret)) {
+ // The link can be relative, we treat this the same as if there was no link
869
+ if (__tzZoneInfo && (0 < ret) && (linkbuf[0] != '.')) {
870
linkbuf[ret] = '\0';
871
const char *tzZoneInfo = CFStringGetCStringPtr(__tzZoneInfo, kCFStringEncodingASCII);
872
size_t zoneInfoDirLen = CFStringGetLength(__tzZoneInfo);
0 commit comments