plugin_init_proc = NULL;
plugin_sync_proc = NULL;
plugin_async_proc = NULL;
+ void* void_pointer;
+ if ((int)(sizeof(void_pointer)) == 8) {
+ g_plugin_handle = dlopen ( PLUGIN_PATH64, RTLD_NOW );
+ }
+ else {
+ g_plugin_handle = dlopen ( PLUGIN_PATH, RTLD_NOW );
+ }
- g_plugin_handle = dlopen ( PLUGIN_PATH, RTLD_NOW );
+ //g_plugin_handle = dlopen ( PLUGIN_PATH, RTLD_NOW );
if ( g_plugin_handle == NULL ) {
- E ( "failed to dlopen(%s). error: %s\n", PLUGIN_PATH, dlerror() );
+ if ((int)(sizeof(void_pointer)) == 8) {
+ E ( "failed to dlopen(%s). error: %s\n", PLUGIN_PATH64, dlerror() );
+ }
+ else {
+ E ( "failed to dlopen(%s). error: %s\n", PLUGIN_PATH, dlerror() );
+ }
return 0;
}
void load_sdbd_plugin()
{
int ret;
+ void* void_pointer;
plugin_cmd_hashtable = hashtable_create ( ht_size_31 );
I ( "using default plugin interface.\n" );
} else {
- D ( "using sdbd plugin interface.(%s)\n", PLUGIN_PATH );
-
+ if ((int)(sizeof(void_pointer)) == 8) {
+ D ( "using sdbd plugin interface.(%s)\n", PLUGIN_PATH64 );
+ }
+ else {
+ D ( "using sdbd plugin interface.(%s)\n", PLUGIN_PATH );
+ }
plugin_init_proc ( plugin_event_handler, plugin_register_command );
readxml();
}
}
return success;
-}
\ No newline at end of file
+}