diff options
author | Jari Vetoniemi <mailroxas@gmail.com> | 2014-04-15 20:06:51 +0300 |
---|---|---|
committer | Jari Vetoniemi <mailroxas@gmail.com> | 2014-04-15 20:06:51 +0300 |
commit | cf27013c1d1790e0d5239aa6fc34999e0f173f30 (patch) | |
tree | a1d21f5063973131494650a82df3f8fb350c36db /lib | |
parent | 5556779dd2b6ac48ef7e137ca0da3ac9190238bf (diff) | |
download | bemenu-cf27013c1d1790e0d5239aa6fc34999e0f173f30.tar.gz bemenu-cf27013c1d1790e0d5239aa6fc34999e0f173f30.tar.bz2 bemenu-cf27013c1d1790e0d5239aa6fc34999e0f173f30.zip |
Print the missing function and from what library in case of exception.
Diffstat (limited to 'lib')
-rw-r--r-- | lib/draw/curses.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/draw/curses.c b/lib/draw/curses.c index f8137b8..afe0a98 100644 --- a/lib/draw/curses.c +++ b/lib/draw/curses.c @@ -410,7 +410,8 @@ int _bmDrawCursesInit(struct _bmRenderApi *api) if (!curses.handle) return 0; -#define bmLoadFunction(x) (curses.x = dlsym(curses.handle, #x)) + char *func = NULL; +#define bmLoadFunction(x) (curses.x = dlsym(curses.handle, (func = #x))) if (!bmLoadFunction(initscr)) goto function_pointer_exception; @@ -471,6 +472,7 @@ int _bmDrawCursesInit(struct _bmRenderApi *api) return 1; function_pointer_exception: + fprintf(stderr, "-!- Could not load function '%s' from '%s'\n", func, DL_PATH[i]); _bmDrawCursesFree(); return 0; } |