projects
/
yaz-moved-to-github.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Better support for extra data for SRU codecs and GFS
[yaz-moved-to-github.git]
/
src
/
srwutil.c
diff --git
a/src/srwutil.c
b/src/srwutil.c
index
a2cf45d
..
b90ca6e
100644
(file)
--- a/
src/srwutil.c
+++ b/
src/srwutil.c
@@
-279,7
+279,7
@@
static void yaz_srw_decodeauth(Z_SRW_PDU *sr, Z_HTTP_Request *hreq,
}
#endif
}
#endif
-void yaz_uri_val_int(const char *path, const char *name, ODR o, int **intp)
+void yaz_uri_val_int(const char *path, const char *name, ODR o, Odr_int **intp)
{
const char *v = yaz_uri_val(path, name, o);
if (v)
{
const char *v = yaz_uri_val(path, name, o);
if (v)
@@
-463,7
+463,7
@@
int yaz_srw_decode(Z_HTTP_Request *hreq, Z_SRW_PDU **srw_pdu,
#if YAZ_HAVE_XML2
static int yaz_sru_decode_integer(ODR odr, const char *pname,
#if YAZ_HAVE_XML2
static int yaz_sru_decode_integer(ODR odr, const char *pname,
- const char *valstr, int **valp,
+ const char *valstr, Odr_int **valp,
Z_SRW_diagnostic **diag, int *num_diag,
int min_value)
{
Z_SRW_diagnostic **diag, int *num_diag,
int min_value)
{
@@
-862,6
+862,8
@@
static Z_SRW_PDU *yaz_srw_get_core_ver(ODR o, const char *version)
p->username = 0;
p->password = 0;
p->extra_args = 0;
p->username = 0;
p->password = 0;
p->extra_args = 0;
+ p->extraResponseData_buf = 0;
+ p->extraResponseData_len = 0;
return p;
}
return p;
}
@@
-1197,13
+1199,13
@@
int yaz_diag_srw_to_bib1(int code)
}
static void add_val_int(ODR o, char **name, char **value, int *i,
}
static void add_val_int(ODR o, char **name, char **value, int *i,
- char *a_name, int *val)
+ char *a_name, Odr_int *val)
{
if (val)
{
name[*i] = a_name;
{
if (val)
{
name[*i] = a_name;
- value[*i] = (char *) odr_malloc(o, 30);
- sprintf(value[*i], "%d", *val);
+ value[*i] = (char *) odr_malloc(o, 40);
+ sprintf(value[*i], ODR_INT_PRINTF, *val);
(*i)++;
}
}
(*i)++;
}
}
@@
-1471,6
+1473,7
@@
void yaz_encode_sru_extra(Z_SRW_PDU *sr, ODR odr, const char *extra_args)
/*
* Local variables:
* c-basic-offset: 4
/*
* Local variables:
* c-basic-offset: 4
+ * c-file-style: "Stroustrup"
* indent-tabs-mode: nil
* End:
* vim: shiftwidth=4 tabstop=8 expandtab
* indent-tabs-mode: nil
* End:
* vim: shiftwidth=4 tabstop=8 expandtab