X-Git-Url: http://git.indexdata.com/?a=blobdiff_plain;f=src%2Fnormalize_record.c;h=373cf6c943b83dc848866284816bb2729029713c;hb=18f2ca94b3cfb8f77ab8444b5afa1479abd00308;hp=9a81fb3ada7c617f3cf2e2e757f64019b3bce984;hpb=8961ed761e348e972f00d015284ce75c16b1648c;p=pazpar2-moved-to-github.git diff --git a/src/normalize_record.c b/src/normalize_record.c index 9a81fb3..373cf6c 100644 --- a/src/normalize_record.c +++ b/src/normalize_record.c @@ -1,5 +1,5 @@ /* This file is part of Pazpar2. - Copyright (C) 2006-2012 Index Data + Copyright (C) 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 @@ -178,6 +178,12 @@ int normalize_record_transform(normalize_record_t nt, xmlDoc **doc, *doc = ndoc; else { + if (!ndoc) + yaz_log(YLOG_WARN, "XSLT produced no document"); + else if (!root) + yaz_log(YLOG_WARN, "XSLT produced XML with no root node"); + else if (!root->children) + yaz_log(YLOG_WARN, "XSLT produced XML with no root children nodes"); if (ndoc) xmlFreeDoc(ndoc); return -1;