/* This file is part of Pazpar2.
- Copyright (C) 2006-2009 Index Data
+ Copyright (C) 2006-2010 Index Data
Pazpar2 is free software; you can redistribute it and/or modify it under
the terms of the GNU General Public License as published by the Free
{
xmlNode *n;
struct conf_server *server = nmem_malloc(nmem, sizeof(struct conf_server));
+ xmlChar *server_id = xmlGetProp(node, (xmlChar *) "id");
server->host = 0;
server->port = 0;
server->mergekey_pct = 0;
server->server_settings = 0;
+ if (server_id)
+ {
+ server->server_id = nmem_strdup(nmem, (const char *)server_id);
+ xmlFree(server_id);
+ }
+ else
+ server->server_id = 0;
for (n = node->children; n; n = n->next)
{
if (n->type != XML_ELEMENT_NODE)
}
else if (!(*sp)->id && !service_id)
{
- yaz_log(YLOG_FATAL, "Duplicate unnamed service '%s'",
- service_id);
+ yaz_log(YLOG_FATAL, "Duplicate unnamed service");
break;
}
{
yaz_log(YLOG_LOG, "Configuration %s after include processing",
fname);
+#if LIBXML_VERSION >= 20600
xmlDocFormatDump(yaz_log_file(), doc, 0);
+#else
+ xmlDocDump(yaz_log_file(), doc);
+#endif
}
r = parse_config(config, n);
}