Use atoll/atoi for ascii to zint conversion in alvis filter.
authorAdam Dickmeiss <adam@indexdata.dk>
Fri, 22 Dec 2006 12:13:39 +0000 (12:13 +0000)
committerAdam Dickmeiss <adam@indexdata.dk>
Fri, 22 Dec 2006 12:13:39 +0000 (12:13 +0000)
configure.ac
index/alvis.c

index af87b2c..73845d8 100644 (file)
@@ -1,5 +1,5 @@
 dnl Zebra, Index Data ApS, 1995-2006
-dnl $Id: configure.ac,v 1.42 2006-11-29 10:24:01 adam Exp $
+dnl $Id: configure.ac,v 1.43 2006-12-22 12:13:39 adam Exp $
 dnl
 AC_PREREQ(2.59)
 AC_INIT([idzebra],[2.0.7],[zebra-help@indexdata.dk])
@@ -107,7 +107,7 @@ else
 fi
 dnl
 dnl ------ various functions
-AC_CHECK_FUNCS(mkstemp)
+AC_CHECK_FUNCS(mkstemp atoll)
 dnl
 dnl ------ GNU Readline
 READLINE_SHARED_LIBADD=""
index 2f91763..851064f 100644 (file)
@@ -1,4 +1,4 @@
-/* $Id: alvis.c,v 1.8 2006-12-13 13:05:45 adam Exp $
+/* $Id: alvis.c,v 1.9 2006-12-22 12:13:40 adam Exp $
    Copyright (C) 1995-2006
    Index Data ApS
 
@@ -434,7 +434,12 @@ static void index_record(struct filter_info *tinfo,struct recExtractCtrl *ctrl,
            sscanf(id_str, "%255s", ctrl->match_criteria);
 
        if (rank_str)
-           ctrl->staticrank = atoi(rank_str);
+           ctrl->staticrank = 
+#if HAVE_ATOLL
+                atoll(rank_str);
+#else
+                atoi(rank_str);
+#endif
        
        ptr = ptr->children;
     }