summaryrefslogtreecommitdiffstats
path: root/sol
diff options
context:
space:
mode:
authorTom Joseph <tomjoseph@in.ibm.com>2017-03-30 08:16:47 +0530
committerPatrick Williams <patrick@stwcx.xyz>2017-04-24 11:22:15 -0500
commit2fd466f415b7b0344483061e4ffa88fdcbce4a18 (patch)
treea250e4eae904414e69d12d36ab146fc9bf29ab3a /sol
parent7306314f605c6232218144db10ae446a367dbe2e (diff)
downloadphosphor-net-ipmid-2fd466f415b7b0344483061e4ffa88fdcbce4a18.tar.gz
phosphor-net-ipmid-2fd466f415b7b0344483061e4ffa88fdcbce4a18.zip
Add resendPayload function
Resolves openbmc/openbmc#856 Change-Id: I957ce889500840c067e97537e825571cfb77e1c4 Signed-off-by: Tom Joseph <tomjoseph@in.ibm.com>
Diffstat (limited to 'sol')
-rw-r--r--sol/sol_context.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/sol/sol_context.cpp b/sol/sol_context.cpp
index 24339f0..ec48a59 100644
--- a/sol/sol_context.cpp
+++ b/sol/sol_context.cpp
@@ -185,7 +185,15 @@ int Context::sendOutboundPayload()
void Context::resendPayload(bool clear)
{
+ sendPayload(payloadCache);
+ if(clear)
+ {
+ payloadCache.clear();
+ expectedCharCount = 0;
+ std::get<sol::Manager&>(singletonPool).dataBuffer.erase(
+ expectedCharCount);
+ }
}
void Context::sendPayload(const Buffer& out) const
OpenPOWER on IntegriCloud