summaryrefslogtreecommitdiff
path: root/cppe/src/IceE/Outgoing.cpp
diff options
context:
space:
mode:
authorDwayne Boone <dwayne@zeroc.com>2007-04-26 19:07:41 +0000
committerDwayne Boone <dwayne@zeroc.com>2007-04-26 19:07:41 +0000
commit8ff8b0052bf9e0121365dca1a99a6334402a58dc (patch)
treeaf43e4491889cb7b795aee946429e866f46ee2e6 /cppe/src/IceE/Outgoing.cpp
parentBug 2149 (diff)
downloadice-8ff8b0052bf9e0121365dca1a99a6334402a58dc.tar.bz2
ice-8ff8b0052bf9e0121365dca1a99a6334402a58dc.tar.xz
ice-8ff8b0052bf9e0121365dca1a99a6334402a58dc.zip
Bug 2149 - context changes
Diffstat (limited to 'cppe/src/IceE/Outgoing.cpp')
-rw-r--r--cppe/src/IceE/Outgoing.cpp11
1 files changed, 8 insertions, 3 deletions
diff --git a/cppe/src/IceE/Outgoing.cpp b/cppe/src/IceE/Outgoing.cpp
index 2dc7074d463..888b33d105a 100644
--- a/cppe/src/IceE/Outgoing.cpp
+++ b/cppe/src/IceE/Outgoing.cpp
@@ -45,7 +45,7 @@ IceInternal::LocalExceptionWrapper::retry() const
}
IceInternal::Outgoing::Outgoing(Connection* connection, Reference* ref, const string& operation,
- OperationMode mode, const Context& context) :
+ OperationMode mode, const Context* context) :
_connection(connection),
_reference(ref),
_state(StateUnsent),
@@ -98,9 +98,14 @@ IceInternal::Outgoing::Outgoing(Connection* connection, Reference* ref, const st
_stream.write(static_cast<Byte>(mode));
- _stream.writeSize(Int(context.size()));
+ if(context == 0)
+ {
+ context = &_reference->getContext()->getValue();
+ }
+
+ _stream.writeSize(Int(context->size()));
Context::const_iterator p;
- for(p = context.begin(); p != context.end(); ++p)
+ for(p = context->begin(); p != context->end(); ++p)
{
_stream.write(p->first);
_stream.write(p->second);