#include <stdio.h>
#include <stdlib.h>
#include <string.h>
-#include <ctype.h>
#ifdef WIN32
#include <process.h>
#include "session.h"
#include <yaz/statserv.h>
#include <yaz/daemon.h>
+#include <yaz/yaz-iconv.h>
static IOCHAN pListener = NULL;
cp = p->content;
if (first)
{
- while(*cp && isspace(*cp))
+ while(*cp && yaz_isspace(*cp))
cp++;
if (*cp)
first = 0; /* reset if we got non-whitespace out */
}
/* remove trailing whitespace */
cp = strlen((const char *)str) + str;
- while (cp != str && isspace(cp[-1]))
+ while (cp != str && yaz_isspace(cp[-1]))
cp--;
*cp = '\0';
/* return resulting string */
}
else if (!strcmp((const char *) ptr->name, "cql2rpn"))
{
- gfs->cql_transform = cql_transform_open_fname(
- nmem_dup_xml_content(gfs_nmem, ptr->children)
- );
+ char *name = nmem_dup_xml_content(gfs_nmem, ptr->children);
+ gfs->cql_transform = cql_transform_open_fname(name);
+ if (!gfs->cql_transform)
+ {
+ yaz_log(YLOG_FATAL|YLOG_ERRNO,
+ "open CQL transform file '%s'", name);
+ exit(1);
+ }
}
else if (!strcmp((const char *) ptr->name, "ccl2rpn"))
{