+ if (zebra_errCode(zh))
+ {
+ yaz_log(YLOG_FATAL, "zebra_records_retrieve returned error %d",
+ zebra_errCode(zh));
+ exit(1);
+ }
+
+ for (j = 0; j < number_to_fetch; j++)
+ {
+ if (!retrievalRecord[j].buf)
+ {
+ yaz_log(YLOG_FATAL, "No record buf at position %d", j);
+ exit(1);
+ }
+ if (!retrievalRecord[j].len)
+ {
+ yaz_log(YLOG_FATAL, "No record len at position %d", j);
+ exit(1);
+ }
+ }