You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mesos.apache.org by bm...@apache.org on 2018/01/09 02:47:38 UTC

[3/3] mesos git commit: Updated the master to use .at for const access to `slaves.unreachable`.

Updated the master to use .at for const access to `slaves.unreachable`.

To prevent accidental insertion of entries when performing const
access, we use the `.at` operator.

Review: https://reviews.apache.org/r/64927


Project: http://git-wip-us.apache.org/repos/asf/mesos/repo
Commit: http://git-wip-us.apache.org/repos/asf/mesos/commit/c398373f
Tree: http://git-wip-us.apache.org/repos/asf/mesos/tree/c398373f
Diff: http://git-wip-us.apache.org/repos/asf/mesos/diff/c398373f

Branch: refs/heads/master
Commit: c398373f12ed99e3712609cb738702bccebc0591
Parents: e989b22
Author: Benjamin Mahler <bm...@apache.org>
Authored: Tue Jan 2 18:36:22 2018 -0800
Committer: Benjamin Mahler <bm...@apache.org>
Committed: Mon Jan 8 18:34:51 2018 -0800

----------------------------------------------------------------------
 src/master/master.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/mesos/blob/c398373f/src/master/master.cpp
----------------------------------------------------------------------
diff --git a/src/master/master.cpp b/src/master/master.cpp
index 28d8be3..1d93c89 100644
--- a/src/master/master.cpp
+++ b/src/master/master.cpp
@@ -8519,7 +8519,7 @@ void Master::_reconcileTasks(
       // does not have the PARTITION_AWARE capability, send TASK_LOST
       // for backward compatibility. In either case, the status update
       // also includes the time when the slave was marked unreachable.
-      const TimeInfo& unreachableTime = slaves.unreachable[slaveId.get()];
+      const TimeInfo& unreachableTime = slaves.unreachable.at(slaveId.get());
 
       TaskState taskState = TASK_UNREACHABLE;
       if (!framework->capabilities.partitionAware) {