Provide API to set socket channel in session object.

Change-Id: I7d9620c4a34bb8bb85ed6f60ac8b2032355087f6
Signed-off-by: Tom Joseph <tomjoseph@in.ibm.com>
diff --git a/message_handler.cpp b/message_handler.cpp
index 8332517..a68f36b 100644
--- a/message_handler.cpp
+++ b/message_handler.cpp
@@ -179,5 +179,13 @@
     return writeStatus;
 }
 
+void Handler::setChannelInSession() const
+{
+    auto session = (std::get<session::Manager&>(singletonPool).getSession(
+                    sessionID)).lock();
+
+    session->channelPtr = channel;
+}
+
 } //namespace message
 
diff --git a/message_handler.hpp b/message_handler.hpp
index 5ab8535..7fd1215 100644
--- a/message_handler.hpp
+++ b/message_handler.hpp
@@ -62,11 +62,14 @@
          */
         int send(Message& outMessage);
 
+        /** @brief Set socket channel in session object */
+        void setChannelInSession() const;
+
         // BMC Session ID for the Channel
         session::SessionID sessionID;
 
     private:
-        // Socket channel for communicating with the remote client
+        /** @brief Socket channel for communicating with the remote client.*/
         std::shared_ptr<udpsocket::Channel> channel;
 
         // IPMI 1.5 or IPMI 2.0 Session Header