* Copyright (c) 1995-2002, Index Data
* See the file LICENSE for details.
*
- * $Id: seshigh.c,v 1.125 2002-01-23 21:13:30 adam Exp $
+ * $Id: seshigh.c,v 1.129 2002-04-18 13:18:47 adam Exp $
*/
/*
#include <yaz/log.h>
#include <yaz/logrpn.h>
#include <yaz/statserv.h>
+#include <yaz/diagbib1.h>
#include <yaz/backend.h>
assoc->init->auth = req->idAuthentication;
assoc->init->referenceId = req->referenceId;
assoc->init->implementation_version = 0;
+ assoc->init->implementation_id = 0;
assoc->init->implementation_name = 0;
assoc->init->bend_sort = NULL;
assoc->init->bend_search = NULL;
resp->implementationName = "GFS/YAZ";
+ if (assoc->init->implementation_id)
+ {
+ char *nv = (char *)
+ odr_malloc (assoc->encode,
+ strlen(assoc->init->implementation_id) + 10 +
+ strlen(resp->implementationId));
+ sprintf (nv, "%s / %s",
+ resp->implementationId, assoc->init->implementation_id);
+ resp->implementationId = nv;
+ }
if (assoc->init->implementation_name)
{
char *nv = (char *)
odr_malloc (assoc->encode, sizeof(*dr));
yaz_log(LOG_LOG, "[%d] %s %s%s", error, diagbib1_str(error),
- addinfo ? " -- " : "", addinfo ? addinfo : "", error);
+ addinfo ? " -- " : "", addinfo ? addinfo : "");
rec->which = Z_Records_NSD;
rec->u.nonSurrogateDiagnostic = dr;
dr->diagnosticSetId =
}
else /* too big entirely */
{
- yaz_log(LOG_DEBUG, "Record > maxrcdsz");
+ yaz_log(LOG_LOG, "Record > maxrcdsz this=%d max=%d", this_length, a->maximumRecordSize);
reclist->records[reclist->num_records] =
surrogatediagrec(a, freq.basename, 17, 0);
reclist->num_records++;
bsrr->errcode = 0;
bsrr->hits = 0;
bsrr->errstring = NULL;
+ bsrr->search_info = NULL;
(assoc->init->bend_search)(assoc->backend, bsrr);
if (!bsrr->request)
return 0;
resp->presentStatus = 0;
}
}
+ resp->additionalSearchInfo = bsrt->search_info;
return apdu;
}
Z_ListEntries *ents = (Z_ListEntries *)
odr_malloc (assoc->encode, sizeof(*ents));
Z_DiagRecs *diagrecs_p = NULL;
- oident *attent;
oident *attset;
bend_scan_rr *bsrr = (bend_scan_rr *)
odr_malloc (assoc->encode, sizeof(*bsrr));
static Z_APDU *process_segmentRequest (association *assoc, request *reqb)
{
- bend_segment_rr request;
+ bend_segment_rr req;
- request.segment = reqb->apdu_request->u.segmentRequest;
- request.stream = assoc->encode;
- request.decode = assoc->decode;
- request.print = assoc->print;
- request.association = assoc;
+ req.segment = reqb->apdu_request->u.segmentRequest;
+ req.stream = assoc->encode;
+ req.decode = assoc->decode;
+ req.print = assoc->print;
+ req.association = assoc;
- (*assoc->init->bend_segment)(assoc->backend, &request);
+ (*assoc->init->bend_segment)(assoc->backend, &req);
return 0;
}