]> git.saurik.com Git - apple/ld64.git/blob - unit-tests/test-cases/kext-basic/mykext.c
ld64-409.12.tar.gz
[apple/ld64.git] / unit-tests / test-cases / kext-basic / mykext.c
1 #include <mach/mach_types.h>
2
3 extern void extern_func();
4
5 int my_global = 3;
6 extern int extern_global;
7
8 kern_return_t mykext_start (kmod_info_t * ki, void * d) {
9 ++my_global;
10 ++extern_global;
11 extern_func();
12 return KERN_SUCCESS;
13 }
14
15
16 kern_return_t mykext_stop (kmod_info_t * ki, void * d) {
17 --my_global;
18 --extern_global;
19 return KERN_SUCCESS;
20 }