From fcfd9a074ff29ffdd52e5eb0ee348fb74f0a0d17 Mon Sep 17 00:00:00 2001 From: Adam Dickmeiss Date: Tue, 20 Sep 2011 11:13:52 +0200 Subject: [PATCH] CQL/CCL to RPN. Checks for leading @ Special case, since @ precedes PQF operators. --- src/querytowrbuf.c | 2 ++ test/cql2pqf/5.5.out | 2 ++ test/cql2pqfsample | 1 + test/test_ccl.c | 7 +++++++ 4 files changed, 12 insertions(+) create mode 100644 test/cql2pqf/5.5.err create mode 100644 test/cql2pqf/5.5.out diff --git a/src/querytowrbuf.c b/src/querytowrbuf.c index 8ca78a2..109fec6 100644 --- a/src/querytowrbuf.c +++ b/src/querytowrbuf.c @@ -24,6 +24,8 @@ void yaz_encode_pqf_term(WRBUF b, const char *term, int len) break; if (len > 0 && i == len) { + if (term[0] == '@') + wrbuf_putc(b, '\\'); for (i = 0; i