X-Git-Url: http://git.indexdata.com/?a=blobdiff_plain;f=index%2Fzebraapi.c;h=efbb91921a517eb8d3cd2099f1d8b1a75061910c;hb=f3d280a5a9ee4a99fbf738d16a8a58d9ef498da2;hp=6b609569e8d39c44230aafe433a1e38fb9e021a7;hpb=10d6b6813c5bb9e7b19a12c241ac4e05f5741605;p=idzebra-moved-to-github.git diff --git a/index/zebraapi.c b/index/zebraapi.c index 6b60956..efbb919 100644 --- a/index/zebraapi.c +++ b/index/zebraapi.c @@ -1,4 +1,4 @@ -/* $Id: zebraapi.c,v 1.227 2006-09-11 22:57:54 adam Exp $ +/* $Id: zebraapi.c,v 1.230 2006-10-12 13:06:00 adam Exp $ Copyright (C) 1995-2006 Index Data ApS @@ -1177,10 +1177,10 @@ ZEBRA_RES zebra_scan(ZebraHandle zh, ODR stream, Z_AttributesPlusTerm *zapt, return ZEBRA_FAIL; } } - res = rpn_scan (zh, stream, zapt, attributeset, - zh->num_basenames, zh->basenames, position, - num_entries, entries, is_partial, limit_rset, 0); - zebra_end_read (zh); + res = rpn_scan(zh, stream, zapt, attributeset, + zh->num_basenames, zh->basenames, position, + num_entries, entries, is_partial, limit_rset); + zebra_end_read(zh); return res; } @@ -2015,6 +2015,12 @@ static ZEBRA_RES zebra_commit_ex(ZebraHandle zh, int clean_only) } zebra_get_state (zh, &val, &seqno); + if (val == 'd') + { + yaz_log(YLOG_WARN, "previous transaction didn't reach commit"); + clean_only = 1; + } + if (rval && *rval) bf_cache (bfs, rval); if (bf_commitExists (bfs)) @@ -2027,9 +2033,6 @@ static ZEBRA_RES zebra_commit_ex(ZebraHandle zh, int clean_only) yaz_log (YLOG_DEBUG, "commit start"); bf_commitExec (bfs); -#ifndef WIN32 - sync (); -#endif } seqno++; zebra_set_state (zh, 'o', seqno);