diff options
author | comex | 2015-01-10 15:40:42 -0500 |
---|---|---|
committer | comex | 2015-01-10 15:40:42 -0500 |
commit | 2ab9357b35d2f8e4e217c570ef8b8c66b7e0a891 (patch) | |
tree | 80d6f0442ad95793c70e54a9ae8e10d18a45dfa3 /test/test-find-syms.c | |
parent | nah - this is nice looking but nonportable (diff) | |
download | substitute-2ab9357b35d2f8e4e217c570ef8b8c66b7e0a891.tar.gz |
simplify
Diffstat (limited to 'test/test-find-syms.c')
-rw-r--r-- | test/test-find-syms.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/test/test-find-syms.c b/test/test-find-syms.c new file mode 100644 index 0000000..0ad033d --- /dev/null +++ b/test/test-find-syms.c @@ -0,0 +1,13 @@ +#include <substitute.h> +#include <stdio.h> +#include <assert.h> +#include <dlfcn.h> + +int main() { + const char *foundation = "/System/Library/Frameworks/Foundation.framework/Foundation"; + dlopen(foundation, RTLD_LAZY); + const char *names[] = { "_setshortValueWithMethod" }; + substitute_sym *syms[1]; + assert(!substitute_find_syms(foundation, names, syms, 1)); + printf("%p\n", syms[0]); +} |