X-Git-Url: http://git.indexdata.com/?a=blobdiff_plain;ds=sidebyside;f=client%2Fclient.c;h=315b5b8fb9550223113276102a899a5e6a2fca8b;hb=b24d2d58cd28380a1969780e5e2d7c4f0719f81c;hp=774a08bbad0ca8869ea421e96f8b06d61162a07a;hpb=109b6408fbe38ca68651a23b59a9ac875e7b8944;p=yaz-moved-to-github.git diff --git a/client/client.c b/client/client.c index 774a08b..315b5b8 100644 --- a/client/client.c +++ b/client/client.c @@ -2,15 +2,10 @@ * Copyright (c) 1995-2001, Index Data * See the file LICENSE for details. * - * $Id: client.c,v 1.127 2001-08-08 19:35:06 adam Exp $ + * $Id: client.c,v 1.129 2001-10-29 09:17:19 adam Exp $ * */ -/* - * This is the obligatory little toy client, whose primary purpose is - * to illustrate the use of the YAZ service-level API. - */ - #include #include #include @@ -494,7 +489,8 @@ static void display_record(Z_DatabaseRecord *p) } } if (ent && ent->value == VAL_SOIF) - print_record((const unsigned char *) r->u.octet_aligned->buf, r->u.octet_aligned->len); + print_record((const unsigned char *) r->u.octet_aligned->buf, + r->u.octet_aligned->len); else if (r->which == Z_External_octet && p->u.octet_aligned->len) { const char *octet_buf = (char*)p->u.octet_aligned->buf; @@ -504,7 +500,9 @@ static void display_record(Z_DatabaseRecord *p) p->u.octet_aligned->len); else { - if (marc_display (octet_buf, NULL) <= 0) + if (marc_display_exl (octet_buf, NULL, 0 /* debug */, + p->u.octet_aligned->len) + <= 0) { printf ("ISO2709 decoding failed, dumping record as is:\n"); print_record((const unsigned char*) octet_buf, @@ -1919,7 +1917,6 @@ static void initialize(void) #if YAZ_MODULE_ccl FILE *inf; #endif - nmem_init(); if (!(out = odr_createmem(ODR_ENCODE)) || !(in = odr_createmem(ODR_DECODE)) || !(print = odr_createmem(ODR_PRINT)))