X-Git-Url: http://git.indexdata.com/?a=blobdiff_plain;f=zutil%2Fzoom-c.c;h=59b051d6aa47095ce235ce1c90438c8a8611f4c1;hb=c71d717ada2a9ef730d527f161eb5ba9aa641a9f;hp=648fba2beb2767935be940c60b062efa97f5e6be;hpb=6607d0bd04b26591614a84a9aa9bad7e7b00e7e9;p=yaz-moved-to-github.git diff --git a/zutil/zoom-c.c b/zutil/zoom-c.c index 648fba2..59b051d 100644 --- a/zutil/zoom-c.c +++ b/zutil/zoom-c.c @@ -2,7 +2,7 @@ * Copyright (c) 2000-2003, Index Data * See the file LICENSE for details. * - * $Id: zoom-c.c,v 1.39 2003-07-14 12:59:23 adam Exp $ + * $Id: zoom-c.c,v 1.41 2003-08-19 12:32:29 adam Exp $ * * ZOOM layer for C, connections, result sets, queries. */ @@ -870,6 +870,7 @@ static zoom_ret send_APDU (ZOOM_connection c, Z_APDU *a) assert (a); if (encode_APDU(c, a, c->odr_out)) return zoom_complete; + yaz_log(LOG_DEBUG, "send APDU type=%d", a->which); c->buf_out = odr_getbuf(c->odr_out, &c->len_out, 0); event = ZOOM_Event_create (ZOOM_EVENT_SEND_APDU); ZOOM_connection_put_event (c, event); @@ -1199,7 +1200,7 @@ static zoom_ret ZOOM_connection_send_search (ZOOM_connection c) { /* Regular piggyback - do it unless we're going to do sort */ *search_req->largeSetLowerBound = 2000000000; - *search_req->smallSetUpperBound = 0; + *search_req->smallSetUpperBound = 1; *search_req->mediumSetPresentNumber = r->step>0 ? r->step : r->count; } else @@ -2505,7 +2506,7 @@ static void handle_apdu (ZOOM_connection c, Z_APDU *apdu) Z_InitResponse *initrs; c->mask = 0; - yaz_log (LOG_DEBUG, "handle_apdu type=%d", apdu->which); + yaz_log (LOG_DEBUG, "recv APDU type=%d", apdu->which); switch(apdu->which) { case Z_APDU_initResponse: @@ -2748,15 +2749,16 @@ static void handle_http(ZOOM_connection c, Z_HTTP_Response *hres) static int do_read (ZOOM_connection c) { - int r; + int r, more; ZOOM_Event event; event = ZOOM_Event_create (ZOOM_EVENT_RECV_DATA); ZOOM_connection_put_event (c, event); - yaz_log (LOG_DEBUG, "do_read len=%d", c->len_in); r = cs_get (c->cs, &c->buf_in, &c->len_in); + more = cs_more(c->cs); + yaz_log (LOG_DEBUG, "do_read len=%d more=%d", r, more); if (r == 1) return 0; if (r <= 0)