Plugin::openModule("qhub-loader.so");
Plugin::openModule("loader");
int main(int argc, char **argv){	signal(SIGINT, &end);	signal(SIGPIPE, SIG_IGN);	signal(SIGALRM, SIG_IGN);#ifdef LINUX	signal(SIGCLD, SIG_IGN);#else	signal(SIGCHLD, SIG_IGN);#endif	//do this here so we don't wind up doing extra	//work if all they want is --version or --help	Settings::parseArgs(argc, argv);#ifdef HAVE_LIBOOP_EVENT	event_init();#endif#ifndef HAVE_LIBOOP_EVENT	oop_source_sys* system;	if((system=oop_sys_new()) == NULL){		log(qerr, "Malloc failure.");		exit(EXIT_FAILURE);	}	src = oop_sys_source(system);	log(qstat, "Using liboop system event source: select() will be used.");#else	src = oop_event_new();	log(qstat, "Using libevent source adapter");#endif	//Set up ADNS	adns = oop_adns_new(src, (adns_initflags)0, NULL);	Settings::readFromXML();	//try loading	Plugin::init();	Plugin::openModule("qhub-loader.so");	//Init random number generator	srand(time(NULL));	struct timer *timer = new struct timer;	gettimeofday(&timer->tv, NULL);	timer->delay = 1000000;	on_timer(src, timer->tv, timer);#ifndef HAVE_LIBOOP_EVENT	oop_sys_run(system);#else	event_dispatch();#endif	return 0;}