X-Git-Url: http://git.indexdata.com/?a=blobdiff_plain;f=index%2Fsortidx.c;h=962841a9bb8d465064471271f9bf9a393c049f87;hb=131e8143a9b8da294d582f0793833679101a2672;hp=ac087833feb2984b70d2916383101237d69e7cd6;hpb=a4d1fff3d8575f7f3db84630cc408fdd8d051f8f;p=idzebra-moved-to-github.git diff --git a/index/sortidx.c b/index/sortidx.c index ac08783..962841a 100644 --- a/index/sortidx.c +++ b/index/sortidx.c @@ -1,5 +1,5 @@ -/* $Id: sortidx.c,v 1.21 2006-12-19 00:25:41 adam Exp $ - Copyright (C) 1995-2006 +/* $Id: sortidx.c,v 1.24 2007-01-15 15:10:17 adam Exp $ + Copyright (C) 1995-2007 Index Data ApS This file is part of the Zebra server. @@ -253,10 +253,10 @@ int zebra_sort_type(zebra_sort_index_t si, int id) else { sf->isam_p = isamb_get_root_ptr(sf->u.isamb); - sf->isam_pp = 0; } break; } + sf->isam_pp = 0; sf->no_inserted = 0; sf->no_deleted = 0; sf->next = si->files; @@ -273,7 +273,7 @@ void zebra_sort_sysno(zebra_sort_index_t si, zint sysno) { sf->no_inserted = 0; sf->no_deleted = 0; - if (new_sysno < si->sysno && sf->isam_pp) + if (sf->isam_pp && new_sysno < si->sysno && sf->isam_pp) { isamb_pp_close(sf->isam_pp); sf->isam_pp = 0; @@ -382,12 +382,8 @@ void zebra_sort_read(zebra_sort_index_t si, char *buf) { struct sort_term st, st_untilbuf; - st.sysno = 99999; if (!sf->isam_pp) - { - yaz_log(YLOG_LOG, "isamb_pp_open " ZINT_FORMAT, sf->isam_p); sf->isam_pp = isamb_pp_open(sf->u.isamb, sf->isam_p, 1); - } if (!sf->isam_pp) return;