Bug 26528: Z39.50/SRU ignore invalid replies
When searching for authorities if an authorities server reply has invalid records none are displayed. At least french BNF SRU server doesn't fully follow norm and can return an error confusing Koha protocol handler which then returns an empty MARC record. This patch silently removed bogus records. To Test: 1- Add BNF SRU server 2- Go to authorities page 3- Add an authority 4- Search for keyword(any) droits de l'homme 5- No result (Internal Server Error) 6- Apply patch 7- restart starman 8- redo 4 9- Many records are displayed Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> (cherry picked from commitd8f34430d1) Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com> (cherry picked from commitcefb8bcf0c) Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>
This commit is contained in:
parent
a363413a4e
commit
ec140944be
|
|
@ -618,6 +618,8 @@ sub Z3950SearchAuth {
|
|||
my $heading;
|
||||
my $heading_authtype_code;
|
||||
$heading_authtype_code = GuessAuthTypeCode($marcrecord);
|
||||
next if ( not defined $heading_authtype_code ) ;
|
||||
|
||||
$heading = C4::AuthoritiesMarc::GetAuthorizedHeading({ record => $marcrecord });
|
||||
|
||||
my $breedingid = ImportBreedingAuth( $marcrecord, $serverhost[$k], $encoding[$k], $heading );
|
||||
|
|
|
|||
Loading…
Reference in New Issue