r17730: cast dlsym result to try to avoid a compiler crash on hpux
authorAndrew Tridgell <tridge@samba.org>
Wed, 23 Aug 2006 00:46:40 +0000 (00:46 +0000)
committerGerald (Jerry) Carter <jerry@samba.org>
Wed, 10 Oct 2007 19:16:33 +0000 (14:16 -0500)
(This used to be commit 217cff9f00e350b769e40ff1d71ebbd5696c2938)

source4/lib/ldb/common/ldb_modules.c

index e863a2beb5dcb7c4d4e22df4810640b2c67205b4..cfb84e446f27e038d4f0be01d05ab92a5f7e5c77 100644 (file)
@@ -221,7 +221,7 @@ int ldb_try_load_dso(struct ldb_context *ldb, const char *name)
                return -1;
        }
 
-       init_fn = dlsym(handle, "init_module");
+       init_fn = (int (*)(void))dlsym(handle, "init_module");
 
        if (init_fn == NULL) {
                ldb_debug(ldb, LDB_DEBUG_ERROR, "no symbol `init_module' found in %s: %s\n", path, dlerror());