diff options
author | Ed Tanous <edtanous@google.com> | 2022-02-28 21:20:59 +0300 |
---|---|---|
committer | Ed Tanous <ed@tanous.net> | 2022-03-07 21:04:33 +0300 |
commit | 8cc8edec45fb504457933c2c3f2625fa876493e6 (patch) | |
tree | 86f7a8028f8b07dbb42a383828c0b456d4c7f4ee /include/webassets.hpp | |
parent | 5b9ef70bd343047bb3c1f204b4a2de1030354704 (diff) | |
download | bmcweb-8cc8edec45fb504457933c2c3f2625fa876493e6.tar.xz |
Don't rely on operator << for object logging
In the upcoming fmt patch, we remove the use of streams, and a number of
our logging statements are relying on them. This commit changes them to
no longer rely on operator>> or operator+ to build their strings. This
alone isn't very useful, but in the context of the next patch makes the
automation able to do a complete conversion of all log statements
automatically.
Tested: enabled logging on local and saw log statements print to console
Signed-off-by: Ed Tanous <edtanous@google.com>
Change-Id: I0e5dc2cf015c6924037e38d547535eda8175a6a1
Diffstat (limited to 'include/webassets.hpp')
-rw-r--r-- | include/webassets.hpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/include/webassets.hpp b/include/webassets.hpp index 8f41f2f4a8..36c3f8d284 100644 --- a/include/webassets.hpp +++ b/include/webassets.hpp @@ -57,7 +57,7 @@ inline void requestRoutes(App& app) std::filesystem::recursive_directory_iterator dirIter(rootpath, ec); if (ec) { - BMCWEB_LOG_ERROR << "Unable to find or open " << rootpath + BMCWEB_LOG_ERROR << "Unable to find or open " << rootpath.string() << " static file hosting disabled"; return; } @@ -117,7 +117,7 @@ inline void requestRoutes(App& app) { // Got a duplicated path. This is expected in certain // situations - BMCWEB_LOG_DEBUG << "Got duplicated path " << webpath; + BMCWEB_LOG_DEBUG << "Got duplicated path " << webpath.string(); continue; } const char* contentType = nullptr; @@ -137,7 +137,7 @@ inline void requestRoutes(App& app) if (contentType == nullptr) { BMCWEB_LOG_ERROR << "Cannot determine content-type for " - << absolutePath << " with extension " + << absolutePath.string() << " with extension " << extension; } |