-/* $Id: test_filter_z3950_client.cpp,v 1.5 2005-10-26 10:55:26 marc Exp $
+/* $Id: test_filter_z3950_client.cpp,v 1.6 2005-10-30 17:13:36 adam Exp $
Copyright (c) 2005, Index Data.
%LICENSE%
#include <stdexcept>
#include "filter_z3950_client.hpp"
+#include "util.hpp"
#include "router_chain.hpp"
#include "session.hpp"
// Create package with Z39.50 init request in it
yp2::Package pack;
- ODR odr = odr_createmem(ODR_ENCODE);
+ yp2::odr odr;
Z_APDU *apdu = zget_APDU(odr, Z_APDU_initRequest);
BOOST_CHECK(apdu);
pack.request() = apdu;
- odr_destroy(odr);
// Put it in router
pack.router(router).move();
// Create package with Z39.50 present request in it
yp2::Package pack;
- ODR odr = odr_createmem(ODR_ENCODE);
+ yp2::odr odr;
Z_APDU *apdu = zget_APDU(odr, Z_APDU_presentRequest);
BOOST_CHECK(apdu);
pack.request() = apdu;
- odr_destroy(odr);
// Put it in router
pack.router(router).move();
// Create package with Z39.50 init request in it
yp2::Package pack;
- ODR odr = odr_createmem(ODR_ENCODE);
+ yp2::odr odr;
Z_APDU *apdu = zget_APDU(odr, Z_APDU_initRequest);
const char *vhost = "localhost:9999";
BOOST_CHECK(apdu);
pack.request() = apdu;
- odr_destroy(odr);
// Put it in router
pack.router(router).move();