summaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorPatrick Venture <venture@google.com>2019-02-01 07:29:47 -0800
committerPatrick Venture <venture@google.com>2019-02-01 07:29:47 -0800
commit2a927e87c37845a33bc387822f2bc8e6e72083ec (patch)
tree85cf7a5f7772cdaa81b602099b8661b0f4483ddd /tools
parent596b681cab9775fef91a930fbd2261129ae67e9d (diff)
downloadphosphor-ipmi-flash-2a927e87c37845a33bc387822f2bc8e6e72083ec.tar.gz
phosphor-ipmi-flash-2a927e87c37845a33bc387822f2bc8e6e72083ec.zip
tools: updater: iterate via string instead of auto
Use a std::string declaration instead of auto to add backwards compatibility and because it's clearly only ever going to be a string and we're doing a c-string check. Change-Id: I89bf9076cdc711209a75684a984a39c058367355 Signed-off-by: Patrick Venture <venture@google.com>
Diffstat (limited to 'tools')
-rw-r--r--tools/updater.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/tools/updater.cpp b/tools/updater.cpp
index 0c45d7b..2620715 100644
--- a/tools/updater.cpp
+++ b/tools/updater.cpp
@@ -22,6 +22,7 @@
#include <algorithm>
#include <cstring>
#include <memory>
+#include <string>
namespace host_tool
{
@@ -41,7 +42,7 @@ void updaterMain(BlobInterface* blob, DataInterface* handler,
*/
std::vector<std::string> blobs = blob->getBlobList();
auto blobInst = std::find_if(
- blobs.begin(), blobs.end(), [&goalFirmware](const auto& iter) {
+ blobs.begin(), blobs.end(), [&goalFirmware](const std::string& iter) {
/* Running into weird scenarios where the string comparison doesn't
* work. TODO: revisit.
*/
OpenPOWER on IntegriCloud