From 4351730550bc48c4237de4e616f8e420e084c081 Mon Sep 17 00:00:00 2001 From: Gordon Sim Date: Fri, 15 Feb 2008 08:26:00 +0000 Subject: * updated c++ build to work with recent gentools changes * add null exchange.bound impl to SessionHandlerImpl (to reflect change to spec file) * pass AMQDataBlocks rather than AMQFrames to OutputHandler * allow client to pass messages frames to io layer in one go (via FrameList) if it will fit in a single buffer git-svn-id: https://svn.apache.org/repos/asf/incubator/qpid/branches/M2.1@627971 13f79535-47bb-0310-9956-ffa450edef68 --- cpp/lib/common/sys/apr/LFSessionContext.cpp | 8 ++++---- cpp/lib/common/sys/apr/LFSessionContext.h | 6 +++--- 2 files changed, 7 insertions(+), 7 deletions(-) (limited to 'cpp/lib/common/sys') diff --git a/cpp/lib/common/sys/apr/LFSessionContext.cpp b/cpp/lib/common/sys/apr/LFSessionContext.cpp index 8a7ce18136..dfe27050c4 100644 --- a/cpp/lib/common/sys/apr/LFSessionContext.cpp +++ b/cpp/lib/common/sys/apr/LFSessionContext.cpp @@ -96,7 +96,7 @@ void LFSessionContext::write(){ if(!framesToWrite.empty()){ out.clear(); bool encoded(false); - AMQFrame* frame = framesToWrite.front(); + AMQDataBlock* frame = framesToWrite.front(); while(frame && out.available() >= frame->size()){ encoded = true; frame->encode(out); @@ -120,7 +120,7 @@ void LFSessionContext::write(){ } } -void LFSessionContext::send(AMQFrame* frame){ +void LFSessionContext::send(AMQDataBlock* frame){ Mutex::ScopedLock l(writeLock); if(!closing){ framesToWrite.push(frame); @@ -173,9 +173,9 @@ void LFSessionContext::init(SessionHandler* _handler){ processor->add(&fd); } -void LFSessionContext::log(const std::string& desc, AMQFrame* const frame){ +void LFSessionContext::log(const std::string& desc, AMQDataBlock* const block){ Mutex::ScopedLock l(logLock); - std::cout << desc << " [" << &socket << "]: " << *frame << std::endl; + std::cout << desc << " [" << &socket << "]: " << *block << std::endl; } Mutex LFSessionContext::logLock; diff --git a/cpp/lib/common/sys/apr/LFSessionContext.h b/cpp/lib/common/sys/apr/LFSessionContext.h index eeb8279d9a..7862055735 100644 --- a/cpp/lib/common/sys/apr/LFSessionContext.h +++ b/cpp/lib/common/sys/apr/LFSessionContext.h @@ -54,7 +54,7 @@ class LFSessionContext : public virtual qpid::sys::SessionContext apr_pollfd_t fd; - std::queue framesToWrite; + std::queue framesToWrite; qpid::sys::Mutex writeLock; bool processing; @@ -62,7 +62,7 @@ class LFSessionContext : public virtual qpid::sys::SessionContext static qpid::sys::Mutex logLock; void log(const std::string& desc, - qpid::framing::AMQFrame* const frame); + qpid::framing::AMQDataBlock* const block); public: @@ -70,7 +70,7 @@ class LFSessionContext : public virtual qpid::sys::SessionContext LFProcessor* const processor, bool debug = false); virtual ~LFSessionContext(); - virtual void send(qpid::framing::AMQFrame* frame); + virtual void send(qpid::framing::AMQDataBlock* frame); virtual void close(); void read(); void write(); -- cgit v1.2.1