X-Git-Url: http://git.indexdata.com/?a=blobdiff_plain;f=src%2Frecord_conv.c;h=372e827947ab402920f694cd4ea1e13732536ced;hb=d940392c53c32ccf76fb287cc5b997b9e921a431;hp=ab5f1732efa5e269178801b919d79dfecdf4d4e4;hpb=0b90ab9b0d18a47201ba1c5883593a14c1e5b148;p=yaz-moved-to-github.git diff --git a/src/record_conv.c b/src/record_conv.c index ab5f173..372e827 100644 --- a/src/record_conv.c +++ b/src/record_conv.c @@ -1,8 +1,6 @@ -/* - * Copyright (C) 2005-2007, Index Data ApS +/* This file is part of the YAZ toolkit. + * Copyright (C) 1995-2008 Index Data * See the file LICENSE for details. - * - * $Id: record_conv.c,v 1.17 2007-12-16 11:08:51 adam Exp $ */ /** * \file record_conv.c @@ -178,21 +176,28 @@ static int conv_xslt(yaz_record_conv_t p, const xmlNode *ptr) if (!yaz_filepath_resolve(stylesheet, p->path, 0, fullpath)) { wrbuf_printf(p->wr_error, "Element :" - " could not locate stylesheet '%s' with path '%s'", - stylesheet, fullpath, p->path); + " could not locate stylesheet '%s'", + stylesheet, fullpath); + if (p->path) + wrbuf_printf(p->wr_error, " with path '%s'", p->path); + return -1; } xsp = xsltParseStylesheetFile((xmlChar*) fullpath); if (!xsp) { - wrbuf_printf(p->wr_error, "Element :" - " parsing stylesheet '%s' with path '%s' failed," + wrbuf_printf(p->wr_error, "Element: :" + " xslt parse failed: %s", stylesheet, fullpath); + if (p->path) + wrbuf_printf(p->wr_error, " with path '%s'", p->path); + wrbuf_printf(p->wr_error, " (" #if YAZ_HAVE_EXSLT - " EXSLT enabled", + + "EXSLT enabled" #else - " EXSLT not supported", + "EXSLT not supported" #endif - stylesheet, fullpath, p->path); + ")"); return -1; } else