Skip to content

Commit 2a5dc17

Browse files
committed
Don't call syscall on tvos
1 parent e750cdc commit 2a5dc17

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

Source/Base/ASSignpost.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ NS_INLINE void ASSignpost(ASSignpostName name, uintptr_t identifier = 0, uintptr
7272
if (kASSignpostsEnabled) {
7373
if (AS_AVAILABLE_IOS_TVOS(10, 10)) {
7474
kdebug_signpost(name, identifier, arg2, 0, ASSignpostGetColor(name, preferred_color));
75-
} else {
75+
} else if (AS_AVAILABLE_IOS(9)) {
7676
syscall(SYS_kdebug_trace, APPSDBG_CODE(DBG_MACH_CHUD, name) | DBG_FUNC_NONE, identifier, arg2, 0, ASSignpostGetColor(name, preferred_color));
7777
}
7878
}
@@ -83,7 +83,7 @@ NS_INLINE void ASSignpostStart(ASSignpostName name, uintptr_t identifier = 0, ui
8383
if (kASSignpostsEnabled) {
8484
if (AS_AVAILABLE_IOS_TVOS(10, 10)) {
8585
kdebug_signpost_start(name, identifier, arg2, 0, 0);
86-
} else {
86+
} else if (AS_AVAILABLE_IOS(9)) {
8787
syscall(SYS_kdebug_trace, APPSDBG_CODE(DBG_MACH_CHUD, name) | DBG_FUNC_START, (uintptr_t)identifier, (uintptr_t)arg2, 0, 0);
8888
}
8989
}
@@ -94,7 +94,7 @@ NS_INLINE void ASSignpostEnd(ASSignpostName name, uintptr_t identifier = 0, uint
9494
if (kASSignpostsEnabled) {
9595
if (AS_AVAILABLE_IOS_TVOS(10, 10)) {
9696
kdebug_signpost_end(name, identifier, arg2, 0, 0);
97-
} else {
97+
} else if (AS_AVAILABLE_IOS(9)) {
9898
syscall(SYS_kdebug_trace, APPSDBG_CODE(DBG_MACH_CHUD, name) | DBG_FUNC_END, identifier, arg2, 0, ASSignpostGetColor(name, preferred_color));
9999
}
100100
}

0 commit comments

Comments
 (0)