[open-ils-commits] [GIT] Evergreen ILS branch rel_2_7 updated. 0a294d7453e864e8c6c25ffc8cd9f7884e49e357
Evergreen Git
git at git.evergreen-ils.org
Tue Aug 18 23:10:03 EDT 2015
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "Evergreen ILS".
The branch, rel_2_7 has been updated
via 0a294d7453e864e8c6c25ffc8cd9f7884e49e357 (commit)
from 1ee6d382348c5849b3ba93eb0f18d083b11e4b6d (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit 0a294d7453e864e8c6c25ffc8cd9f7884e49e357
Author: Dan Scott <dscott at laurentian.ca>
Date: Thu Mar 12 16:06:16 2015 -0400
LP1431541: SRU UTF8 encoding issues
The SuperCat SRU service was encoding MARCXML using an encode_utf8()
call that ended up corrupting non-ASCII characters. In addition, the
HTTP header charset was not being set, meaning that the return header
would default to ISO-8859-1.
Signed-off-by: Dan Scott <dscott at laurentian.ca>
Signed-off-by: Ben Shum <bshum at biblio.org>
diff --git a/Open-ILS/src/perlmods/lib/OpenILS/WWW/SuperCat.pm b/Open-ILS/src/perlmods/lib/OpenILS/WWW/SuperCat.pm
index 873b956..521b66c 100644
--- a/Open-ILS/src/perlmods/lib/OpenILS/WWW/SuperCat.pm
+++ b/Open-ILS/src/perlmods/lib/OpenILS/WWW/SuperCat.pm
@@ -1969,8 +1969,7 @@ sub sru_search {
}
}
- # Ensure the data is encoded as UTF8 before we hand it off
- $marcxml = encode_utf8($marc->as_xml_record());
+ $marcxml = $marc->as_xml_record();
$marcxml =~ s/^<\?xml version="1.0" encoding="UTF-8"\?>//o;
}
@@ -1999,7 +1998,7 @@ sub sru_search {
);
}
- print $cgi->header( -type => 'application/xml' );
+ print $cgi->header( -type => 'application/xml', -charset => 'UTF-8' );
print $U->entityize($resp->asXML) . "\n";
return Apache2::Const::OK;
}
@@ -2116,7 +2115,7 @@ sub sru_auth_search {
);
}
- print $cgi->header( -type => 'application/xml' );
+ print $cgi->header( -type => 'application/xml', -charset => 'UTF-8' );
print $U->entityize($resp->asXML) . "\n";
return Apache2::Const::OK;
}
-----------------------------------------------------------------------
Summary of changes:
Open-ILS/src/perlmods/lib/OpenILS/WWW/SuperCat.pm | 7 +++----
1 files changed, 3 insertions(+), 4 deletions(-)
hooks/post-receive
--
Evergreen ILS
More information about the open-ils-commits
mailing list