Skip to content

Commit c40d554

Browse files
committed
need to guard definition of _dispatch_data_destructor_munmap
Signed-off-by: Daniel A. Steffen <dsteffen@apple.com>
1 parent acea647 commit c40d554

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/data.c

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -108,11 +108,12 @@ const dispatch_block_t _dispatch_data_destructor_none = ^{
108108
DISPATCH_INTERNAL_CRASH(0, "none destructor called");
109109
};
110110

111+
#if !HAVE_MACH
111112
const dispatch_block_t _dispatch_data_destructor_munmap = ^{
112113
DISPATCH_INTERNAL_CRASH(0, "munmap destructor called");
113114
};
114-
115-
#if HAVE_MACH
115+
#else
116+
// _dispatch_data_destructor_munmap is a linker alias to the following
116117
const dispatch_block_t _dispatch_data_destructor_vm_deallocate = ^{
117118
DISPATCH_INTERNAL_CRASH(0, "vmdeallocate destructor called");
118119
};

0 commit comments

Comments
 (0)