regex_debug.c: Stop including dlfcn.h
Since the block of code has been disabled anyway and is not very portable, we introduce a define to control both the include and the code.
This commit is contained in:
parent
102b9593dc
commit
124b4c381b
1 changed files with 6 additions and 3 deletions
|
|
@ -3,13 +3,16 @@
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
|
|
||||||
|
#define USE_DLADDR (0)
|
||||||
|
|
||||||
|
#if USE_DLADDR
|
||||||
// This is some spectacularly non-portable code... but whee!
|
// This is some spectacularly non-portable code... but whee!
|
||||||
#include <dlfcn.h>
|
#include <dlfcn.h>
|
||||||
char* getsym(void* addr) {
|
#endif
|
||||||
|
|
||||||
|
char* getsym(HSVMActionFunc addr) {
|
||||||
char* retstr;
|
char* retstr;
|
||||||
#if 0
|
#if USE_DLADDR
|
||||||
// This will be fixed later.
|
// This will be fixed later.
|
||||||
Dl_info dli;
|
Dl_info dli;
|
||||||
if (dladdr(addr, &dli) != 0 && dli.dli_sname != NULL) {
|
if (dladdr(addr, &dli) != 0 && dli.dli_sname != NULL) {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue