struct db_api {
int (*db_open)(char *);
void (*db_close)(void);
...
};
struct db_api plugin_functions = {
db_open, /* Provided function from dbmysql.c */
db_close
...
};
Where ever the hell this thing is loaded
lt_dlinit();
lt_dlhandle handle = lt_dlopen((value spit out from GetConfigValue));
struct db_api *foo;
foo = lt_dlsym(handle, "plugin_functions");
so, 'foo' is your ticket to all the functions in the module
then since itd be a pretty hefty job to do all that rename to
foo->db_open. We could just provide generic functions that just call
foo->db_*.
Dan Weber
signature.asc
Description: OpenPGP digital signature
