X-Git-Url: http://lists.indexdata.com/cgi-bin?a=blobdiff_plain;f=src%2Fgduutil.cpp;h=4d02d2de04d25d324d65ebc42ba1f81ac6e096ef;hb=e0274b6e40958df2e422b1e3db69a9bc710f5357;hp=c154b67ebbd234a03af51a767a1c79e8b3bd2a55;hpb=dad313c700b9ff9b4728d1b8ef4a0ab5bedf86b1;p=metaproxy-moved-to-github.git diff --git a/src/gduutil.cpp b/src/gduutil.cpp index c154b67..4d02d2d 100644 --- a/src/gduutil.cpp +++ b/src/gduutil.cpp @@ -1,5 +1,5 @@ -/* $Id: gduutil.cpp,v 1.14 2006-10-04 11:21:47 marc Exp $ - Copyright (c) 2005-2006, Index Data. +/* $Id: gduutil.cpp,v 1.17 2007-01-25 14:05:54 adam Exp $ + Copyright (c) 2005-2007, Index Data. See the LICENSE file for details */ @@ -16,7 +16,10 @@ namespace mp = metaproxy_1; // Doxygen doesn't like mp::gdu, so we use this instead -namespace mp_gdu = metaproxy_1::gdu; +namespace mp_util = metaproxy_1::util; + + + std::ostream& std::operator<<(std::ostream& os, Z_GDU& zgdu) { @@ -234,11 +237,12 @@ std::ostream& std::operator<<(std::ostream& os, Z_APDU& zapdu) os << " " <<(oid_getentbyoid(pr->preferredRecordSyntax))->desc; else os << " -"; - //elements - //if (pr->) - // os << " " << *(pr->); - //else - // os << " -"; + const char * msg = 0; + if (pr->recordComposition + && (msg = mp_util::record_composition_to_esn(pr->recordComposition))) + os << " " << msg; + else + os << " -"; } break; case Z_APDU_presentResponse: