-/*
- * Copyright (C) 1995-2002, Index Data
- * All rights reserved.
- * Sebastian Hammer, Adam Dickmeiss
- *
- * $Id: zrpn.c,v 1.118 2002-08-01 08:53:35 adam Exp $
- */
+/* $Id: zrpn.c,v 1.120 2002-08-02 19:26:56 adam Exp $
+ Copyright (C) 1995,1996,1997,1998,1999,2000,2001,2002
+ Index Data Aps
+
+This file is part of the Zebra server.
+
+Zebra 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
+Software Foundation; either version 2, or (at your option) any later
+version.
+
+Zebra is distributed in the hope that it will be useful, but WITHOUT ANY
+WARRANTY; without even the implied warranty of MERCHANTABILITY or
+FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
+for more details.
+
+You should have received a copy of the GNU General Public License
+along with Zebra; see the file LICENSE.zebra. If not, write to the
+Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
+02111-1307, USA.
+*/
+
+
#include <stdio.h>
#include <assert.h>
#ifdef WIN32
if (i)
memcpy (p->u.relation.value, cp - i, i);
p->u.relation.value[i] = 0;
+ yaz_log (LOG_LOG, "value=%s", p->u.relation.value);
cp++;
}
zh->errString = basenames[base_no];
return rset;
}
- if (level > 0 && xpath[level-1].part[0] == '@')
- {
- rset_between_parms parms;
- RSET rset_start_attr, rset_end_attr;
- --level;
- rset_start_attr = xpath_trunc(zh, stream,
- '0', xpath[level].part+1,
- 3, curAttributeSet);
-
- rset_end_attr = xpath_trunc(zh, stream,
- '0', xpath[level].part+1,
- 4, curAttributeSet);
-
- parms.key_size = sizeof(struct it_key);
- parms.cmp = key_compare_it;
- parms.rset_l = rset_start_attr;
- parms.rset_m = rset;
- parms.rset_r = rset_end_attr;
- parms.rset_attr = 0;
- parms.printer = key_print_it;
- rset = rset_create (rset_kind_between, &parms);
- }
while (--level >= 0)
{
char xpath_rev[128];
memcpy (xpath_rev + len, "[^/]*", 5);
len += 5;
}
+ else if (*cp == ' ')
+ {
+
+ xpath_rev[len++] = 1;
+ xpath_rev[len++] = ' ';
+ }
+
else
xpath_rev[len++] = *cp;
xpath_rev[len++] = '/';