projects
/
yazpp-moved-to-github.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Version 1.3.3
[yazpp-moved-to-github.git]
/
src
/
yaz-z-assoc.cpp
diff --git
a/src/yaz-z-assoc.cpp
b/src/yaz-z-assoc.cpp
index
6048465
..
da2156d
100644
(file)
--- a/
src/yaz-z-assoc.cpp
+++ b/
src/yaz-z-assoc.cpp
@@
-24,7
+24,7
@@
int Z_Assoc::yaz_init_func()
return 1;
}
return 1;
}
-int Z_Assoc::yaz_init_flag = Z_Assoc::yaz_init_func();
+int Z_Assoc::yaz_init_flag = Z_Assoc::yaz_init_func();
Z_Assoc::Z_Assoc(IPDU_Observable *the_PDU_Observable)
{
Z_Assoc::Z_Assoc(IPDU_Observable *the_PDU_Observable)
{
@@
-49,7
+49,7
@@
void Z_Assoc::set_APDU_log(const char *fname)
delete [] m_APDU_fname;
m_APDU_fname = 0;
delete [] m_APDU_fname;
m_APDU_fname = 0;
- if (fname)
+ if (fname)
{
m_APDU_fname = new char[strlen(fname)+1];
strcpy (m_APDU_fname, fname);
{
m_APDU_fname = new char[strlen(fname)+1];
strcpy (m_APDU_fname, fname);
@@
-77,7
+77,7
@@
const char *Z_Assoc::get_APDU_log()
Z_Assoc::~Z_Assoc()
{
Z_Assoc::~Z_Assoc()
{
- m_PDU_Observable->destroy();
+ m_PDU_Observable->destroy();
delete m_PDU_Observable;
odr_destroy (m_odr_print); // note: also runs fclose on m_APDU_file ..
odr_destroy (m_odr_out);
delete m_PDU_Observable;
odr_destroy (m_odr_print); // note: also runs fclose on m_APDU_file ..
odr_destroy (m_odr_out);
@@
-120,7
+120,7
@@
Z_ReferenceId **Z_Assoc::get_referenceIdP(Z_APDU *apdu)
switch (apdu->which)
{
case Z_APDU_initRequest:
switch (apdu->which)
{
case Z_APDU_initRequest:
- return &apdu->u.initRequest->referenceId;
+ return &apdu->u.initRequest->referenceId;
case Z_APDU_initResponse:
return &apdu->u.initResponse->referenceId;
case Z_APDU_searchRequest:
case Z_APDU_initResponse:
return &apdu->u.initResponse->referenceId;
case Z_APDU_searchRequest:
@@
-223,8
+223,8
@@
Z_GDU *Z_Assoc::decode_GDU(const char *buf, int len)
if (len > 0)
{
WRBUF w = wrbuf_alloc();
if (len > 0)
{
WRBUF w = wrbuf_alloc();
- wrbuf_write_escaped(w, buf, len > 20 ? 20 : len);
- yaz_log(YLOG_LOG, "Buffer content: %s", wrbuf_cstr(w));
+ wrbuf_write_escaped(w, buf, len > 1024 ? 1024 : len);
+ yaz_log(YLOG_LOG, "Buffer bytes: %s", wrbuf_cstr(w));
wrbuf_destroy(w);
}
yaz_log(YLOG_LOG, "PDU dump:");
wrbuf_destroy(w);
}
yaz_log(YLOG_LOG, "PDU dump:");
@@
-258,7
+258,7
@@
int Z_Assoc::encode_GDU(Z_GDU *apdu, char **buf, int *len)
if (!r) // decoding failed. Get the failed element
element = odr_getelement(m_odr_out);
if (!r) // decoding failed. Get the failed element
element = odr_getelement(m_odr_out);
-
+
if (m_APDU_yazlog || !r)
{
if (!r)
if (m_APDU_yazlog || !r)
{
if (!r)