Remove a few YLOG_LOGs
[idzebra-moved-to-github.git] / rset / rsprox.c
index 77aa4a7..9525eb9 100644 (file)
@@ -1,4 +1,4 @@
-/* $Id: rsprox.c,v 1.24 2005-01-17 01:16:37 adam Exp $
+/* $Id: rsprox.c,v 1.27 2005-04-26 10:09:38 adam Exp $
    Copyright (C) 1995-2005
    Index Data ApS
 
@@ -25,7 +25,7 @@ Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
 #include <string.h>
 #include <assert.h>
 
-#include <zebrautl.h>
+#include <idzebra/util.h>
 #include <rset.h>
 
 #ifndef RSET_DEBUG
@@ -54,8 +54,6 @@ static const struct rset_control control =
     r_write,
 };
 
-const struct rset_control *rset_kind_prox = &control;
-
 struct rset_prox_info {
     RSET *rset;   /* array of 'child' rsets */
     int rset_no;  /* how many of them */
@@ -94,7 +92,6 @@ RSET rsprox_create( NMEM nmem, const struct key_control *kcontrol, int scope,
     return rnew;
 }
 
-
 static void r_delete (RSET ct)
 {
     struct rset_prox_info *info = (struct rset_prox_info *) ct->priv;
@@ -104,7 +101,6 @@ static void r_delete (RSET ct)
         rset_delete(info->rset[i]);
 }
 
-
 static RSFD r_open (RSET ct, int flag)
 {
     struct rset_prox_info *info = (struct rset_prox_info *) ct->priv;
@@ -245,7 +241,7 @@ static int r_forward (RSFD rfd, void *buf, TERMID *term, const void *untilbuf)
                 
                 for (i = 0; i<n; i++)
                 {
-                    int diff = (*kctrl->getseq)(p->buf[1]) - seqno[i];
+                    zint diff = (*kctrl->getseq)(p->buf[1]) - seqno[i];
                     int excl = info->exclusion;
                     if (!info->ordered && diff < 0)
                         diff = -diff;
@@ -333,7 +329,7 @@ static void r_pos (RSFD rfd, double *current, double *total)
         *total = 0;
     } else {
         r = scur/stot; 
-        *current = p->hits;
+        *current = (double) p->hits;
         *total=*current/r ; 
     }
     yaz_log(YLOG_DEBUG,"prox_pos: [%d] %0.1f/%0.1f= %0.4f ",