summaryrefslogtreecommitdiff
path: root/redfish-core/lib/log_services.hpp
diff options
context:
space:
mode:
authorJason M. Bills <jason.m.bills@intel.com>2022-06-24 20:52:05 +0300
committerEd Tanous <ed@tanous.net>2022-06-28 03:07:06 +0300
commitd405bb51fb420ee9318b1cdc13c791db2f56b99c (patch)
treebbc3543f98a020e9b57dca0e19b92982ee294e15 /redfish-core/lib/log_services.hpp
parent3a48b3a27ffbe86d931fb4eb771baa136d5baf2b (diff)
downloadbmcweb-d405bb51fb420ee9318b1cdc13c791db2f56b99c.tar.xz
log_services: don't replace res.jsonValue
There were places where res.jsonValue was being replaced by assigning a new object. This changes those to use res.jsonValue.update() to replace the contents instead of the entire object. Tested: Confirmed that individual event, journal, and crashdump entries can still be retrieved. Change-Id: I8a0885530af58393d4b90fe15390db8c3af02994 Signed-off-by: Jason M. Bills <jason.m.bills@intel.com>
Diffstat (limited to 'redfish-core/lib/log_services.hpp')
-rw-r--r--redfish-core/lib/log_services.hpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/redfish-core/lib/log_services.hpp b/redfish-core/lib/log_services.hpp
index 0a1686674e..6fee6edd00 100644
--- a/redfish-core/lib/log_services.hpp
+++ b/redfish-core/lib/log_services.hpp
@@ -1289,7 +1289,7 @@ inline void requestRoutesJournalEventLogEntry(App& app)
messages::internalError(asyncResp->res);
return;
}
- asyncResp->res.jsonValue = std::move(bmcLogEntry);
+ asyncResp->res.jsonValue.update(bmcLogEntry);
return;
}
}
@@ -2315,7 +2315,7 @@ inline void requestRoutesBMCJournalLogEntry(App& app)
messages::internalError(asyncResp->res);
return;
}
- asyncResp->res.jsonValue = std::move(bmcJournalLogEntry);
+ asyncResp->res.jsonValue.update(bmcJournalLogEntry);
});
}
@@ -2801,7 +2801,7 @@ static void
}
else
{
- logEntryJson = logEntry;
+ logEntryJson.update(logEntry);
}
};
crow::connections::systemBus->async_method_call(