From: Adam Dickmeiss Date: Wed, 21 May 2014 11:56:43 +0000 (+0200) Subject: zoom: Do not include ZOOM C's fake surrogate diag recs MP-547 X-Git-Tag: v1.5.2~1 X-Git-Url: http://sru.miketaylor.org.uk/cgi-bin?a=commitdiff_plain;h=d5f308247c260a15729ce7b5fb2933c778c75b2b;p=metaproxy-moved-to-github.git zoom: Do not include ZOOM C's fake surrogate diag recs MP-547 --- diff --git a/src/filter_zoom.cpp b/src/filter_zoom.cpp index e2145a5..db3719a 100644 --- a/src/filter_zoom.cpp +++ b/src/filter_zoom.cpp @@ -1732,8 +1732,19 @@ Z_Records *yf::Zoom::Frontend::get_records(mp::Package &package, if (!*error) { for (i = 0; i < number_to_present; i++) + { if (!recs[i]) break; + + const char *addinfo; + int sur_error = ZOOM_record_error(recs[i], 0 /* msg */, + &addinfo, 0 /* diagset */); + if (sur_error == + YAZ_BIB1_SYSTEM_ERROR_IN_PRESENTING_RECORDS && addinfo && + !strcmp(addinfo, + "ZOOM C generated. Present phase and no records")) + break; + } } if (i > 0) { // only return records if no error and at least one record