Bugzilla – Attachment 119733 Details for
Bug 26528
Koha return no result if there's invalid records in Z39.50/SRU server reply
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 26528: Z39.50/SRU ignore invalid replies
Bug-26528-Z3950SRU-ignore-invalid-replies.patch (text/plain), 1.54 KB, created by
Kyle M Hall (khall)
on 2021-04-16 13:25:32 UTC
(
hide
)
Description:
Bug 26528: Z39.50/SRU ignore invalid replies
Filename:
MIME Type:
Creator:
Kyle M Hall (khall)
Created:
2021-04-16 13:25:32 UTC
Size:
1.54 KB
patch
obsolete
>From eda2847ba24357ad337015c0a88021c8ff75f8c5 Mon Sep 17 00:00:00 2001 >From: Didier Gautheron <didier.gautheron@biblibre.com> >Date: Thu, 24 Sep 2020 10:13:08 +0200 >Subject: [PATCH] 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> >--- > C4/Breeding.pm | 2 ++ > 1 file changed, 2 insertions(+) > >diff --git a/C4/Breeding.pm b/C4/Breeding.pm >index 2a4ce3c2ac..6b103b3cdb 100644 >--- a/C4/Breeding.pm >+++ b/C4/Breeding.pm >@@ -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 ); >-- >2.24.3 (Apple Git-128)
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 26528
:
110638
|
119033
| 119733