session: start tracking active path for session

Start tracking the active path that corresponds to the session.

Change-Id: I3ca309b7dda89aa40719815cb0f9ee50fabd3d10
Signed-off-by: Patrick Venture <venture@google.com>
diff --git a/firmware_handler.hpp b/firmware_handler.hpp
index e3f9f3b..c87e635 100644
--- a/firmware_handler.hpp
+++ b/firmware_handler.hpp
@@ -19,6 +19,17 @@
 struct Session
 {
     /**
+     * Built a session object.
+     *
+     * @param[in] the active path to which this corresponds.
+     */
+    explicit Session(const std::string& path) :
+        dataHandler(nullptr), imageHandler(nullptr), flags(0),
+        state(State::closed), activePath(path)
+    {
+    }
+
+    /**
      * Pointer to the correct Data handler interface. (nullptr on BT (or KCS))
      */
     DataInterface* dataHandler;
@@ -41,6 +52,9 @@
 
     /** The current state of this session. */
     State state;
+
+    /** The active path. */
+    std::string activePath;
 };
 
 struct ExtChunkHdr
@@ -108,8 +122,9 @@
                         const std::vector<DataHandlerPack>& transports,
                         std::uint16_t bitmask) :
         handlers(firmwares),
-        blobIDs(blobs), transports(transports), bitmask(bitmask), activeImage(),
-        activeHash(), lookup(), state(UpdateState::notYetStarted)
+        blobIDs(blobs), transports(transports), bitmask(bitmask),
+        activeImage(activeImageBlobID), activeHash(activeHashBlobID), lookup(),
+        state(UpdateState::notYetStarted)
     {
     }
     ~FirmwareBlobHandler() = default;