Skip to content

Commit 6d83ad5

Browse files
authored
Merge pull request swiftlang#403 from adierking/detach
Fix the signature of _dispatch_install_thread_detach_callback()
2 parents e99de71 + 9feba93 commit 6d83ad5

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

private/queue_private.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -342,7 +342,7 @@ dispatch_async_enforce_qos_class_f(dispatch_queue_t queue,
342342
* "detached" before the thread exits or the application will crash.
343343
*/
344344
DISPATCH_EXPORT
345-
void _dispatch_install_thread_detach_callback(dispatch_function_t cb);
345+
void _dispatch_install_thread_detach_callback(void (*cb)(void));
346346
#endif
347347

348348
__END_DECLS

src/queue.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -953,7 +953,7 @@ gettid(void)
953953
static void (*_dispatch_thread_detach_callback)(void);
954954

955955
void
956-
_dispatch_install_thread_detach_callback(dispatch_function_t cb)
956+
_dispatch_install_thread_detach_callback(void (*cb)(void))
957957
{
958958
if (os_atomic_xchg(&_dispatch_thread_detach_callback, cb, relaxed)) {
959959
DISPATCH_CLIENT_CRASH(0, "Installing a thread detach callback twice");

0 commit comments

Comments
 (0)