+12 March 2009: Wouter
+ - log to App.logs on windows prints executable identity.
+ - fixup tests.
+
11 March 2009: Wouter
- winsock event handler resets WSAevents after signalled.
- winsock event handler tests if signals are really signalled.
#include "util/net_help.h"
#include "util/regional.h"
#include "iterator/iterator.h"
+#include "iterator/iter_fwd.h"
#include "validator/validator.h"
#include "services/localzone.h"
#ifdef HAVE_PWD_H
localzonechecks(cfg);
}
+/** check forwards */
+static void
+check_fwd(struct config_file* cfg)
+{
+ struct iter_forwards* fwd = forwards_create();
+ if(!fwd || !forwards_apply_cfg(fwd, cfg)) {
+ fatal_exit("Could not set forward zones");
+ }
+ forwards_delete(fwd);
+}
+
/** check config file */
static void
checkconf(const char* cfgfile, const char* opt)
morechecks(cfg, cfgfile);
check_mod(cfg, iter_get_funcblock());
check_mod(cfg, val_get_funcblock());
+ check_fwd(cfg);
if(opt) print_option(cfg, opt);
else printf("unbound-checkconf: no errors in %s\n", cfgfile);
config_delete(cfg);
}
void wsvc_command_option(const char* ATTR_UNUSED(wopt),
- const char* ATTR_UNUSED(cfgfile), int ATTR_UNUSED(v))
+ const char* ATTR_UNUSED(cfgfile), int ATTR_UNUSED(v),
+ int ATTR_UNUSED(c))
{
log_assert(0);
}
void wsvc_setup_worker(struct worker* ATTR_UNUSED(worker))
{
- log_assert(0);
+ /* do nothing */
}
void worker_win_stop_cb(int ATTR_UNUSED(fd), short ATTR_UNUSED(ev),
tp=MSG_GENERIC_SUCCESS;
wt=EVENTLOG_SUCCESS;
}
- snprintf(m, sizeof(m), "[unbound:%x] %s: %s",
- tid?*tid:0, type, message);
+ snprintf(m, sizeof(m), "[%s:%x] %s: %s",
+ ident, tid?*tid:0, type, message);
s = RegisterEventSource(NULL, SERVICE_NAME);
if(!s) return;
ReportEvent(s, wt, 0, tp, NULL, 1, 0, &str, NULL);