64-bit BER integers. Fixes bug #114.
[yaz-moved-to-github.git] / src / rpn2cql.c
index 7a5b9ca..692c55a 100644 (file)
@@ -1,5 +1,5 @@
 /* This file is part of the YAZ toolkit.
- * Copyright (C) 1995-2008 Index Data
+ * Copyright (C) 1995-2009 Index Data
  * See the file LICENSE for details.
  */
 
@@ -86,7 +86,7 @@ static int rpn2cql_simple(cql_transform_t ct,
             sterm = (const char *) term->u.general->buf;
             break;
         case Z_Term_numeric:
-            wrbuf_printf(w, "%d", *term->u.numeric);
+            wrbuf_printf(w, ODR_INT_PRINTF, *term->u.numeric);
             break;
         case Z_Term_characterString:
             sterm = term->u.characterString;
@@ -99,7 +99,7 @@ static int rpn2cql_simple(cql_transform_t ct,
 
         if (term)
         {
-            int i;
+            size_t i;
             int must_quote = 0;
             for (i = 0 ; i < lterm; i++)
                 if (sterm[i] == ' ')
@@ -181,6 +181,7 @@ int cql_transform_rpn2cql_wrbuf(cql_transform_t ct,
 /*
  * Local variables:
  * c-basic-offset: 4
+ * c-file-style: "Stroustrup"
  * indent-tabs-mode: nil
  * End:
  * vim: shiftwidth=4 tabstop=8 expandtab