projects
/
metaproxy-moved-to-github.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
0bf2433
)
zoom fix: convert backend SRU diagnostics.
author
Adam Dickmeiss
<adam@indexdata.dk>
Fri, 29 Jul 2011 14:02:25 +0000
(16:02 +0200)
committer
Adam Dickmeiss
<adam@indexdata.dk>
Fri, 29 Jul 2011 14:02:25 +0000
(16:02 +0200)
The zoom filter speaks Z39.50 and thus SRU diagnostics must be converted
to Z39.50 diagnostics.
src/filter_zoom.cpp
patch
|
blob
|
history
diff --git
a/src/filter_zoom.cpp
b/src/filter_zoom.cpp
index
cd233b5
..
2ac339d
100644
(file)
--- a/
src/filter_zoom.cpp
+++ b/
src/filter_zoom.cpp
@@
-198,7
+198,8
@@
void yf::Zoom::Backend::get_zoom_error(int *error, char **addinfo,
{
const char *msg = 0;
const char *zoom_addinfo = 0;
- *error = ZOOM_connection_error(m_connection, &msg, &zoom_addinfo);
+ const char *dset = 0;
+ *error = ZOOM_connection_error_x(m_connection, &msg, &zoom_addinfo, &dset);
if (*error)
{
if (*error >= ZOOM_ERROR_CONNECT)
@@
-218,6
+219,8
@@
void yf::Zoom::Backend::get_zoom_error(int *error, char **addinfo,
}
else
{
+ if (dset && !strcmp(dset, "info:srw/diagnostic/1"))
+ *error = yaz_diag_srw_to_bib1(*error);
*addinfo = (char *) odr_malloc(
odr, 20 + (zoom_addinfo ? strlen(zoom_addinfo) : 0));
**addinfo = '\0';