X-Git-Url: https://git.saurik.com/apple/dyld.git/blobdiff_plain/d3f1e533acc7f70659b8bde9b6c040974f05e03b..bc3b7c8cda49ed8598284a489c0bb9694c67c6a4:/testing/kernel-cache-tests/vtable-patching-metaclass-alias/foo.c?ds=sidebyside diff --git a/testing/kernel-cache-tests/vtable-patching-metaclass-alias/foo.c b/testing/kernel-cache-tests/vtable-patching-metaclass-alias/foo.c new file mode 100644 index 0000000..5b7b9be --- /dev/null +++ b/testing/kernel-cache-tests/vtable-patching-metaclass-alias/foo.c @@ -0,0 +1,10 @@ + +// This is the symbol xnu now exports +extern int symbol_from_xnu() __asm("__ZN15OSMetaClassBase8DispatchE5IORPC"); + +// And this is the old symbol it needs to implicitly alias to the above symbol +extern int symbol_from_xnu_implicit_alias() __asm("__ZN15OSMetaClassBase25_RESERVEDOSMetaClassBase3Ev"); + +int foo() { + return symbol_from_xnu() + symbol_from_xnu_implicit_alias(); +}