summaryrefslogtreecommitdiffstats
path: root/messagebus
diff options
context:
space:
mode:
authorHenning Baldersheim <balder@yahoo-inc.com>2020-03-24 15:15:14 +0000
committerHenning Baldersheim <balder@yahoo-inc.com>2020-03-24 15:15:14 +0000
commitb655712df5281f7dcf8156429b9ddc9a87e49873 (patch)
tree5622a69e0048872d9860d79fab9d23ab246a2691 /messagebus
parent3b22ac90c3c55128963bf29702604549ed651549 (diff)
Improve readability by signaling that you are operating on a pointer.
Diffstat (limited to 'messagebus')
-rw-r--r--messagebus/src/vespa/messagebus/routing/routingnode.cpp16
1 files changed, 8 insertions, 8 deletions
diff --git a/messagebus/src/vespa/messagebus/routing/routingnode.cpp b/messagebus/src/vespa/messagebus/routing/routingnode.cpp
index 77a164eddf9..a47abe185cc 100644
--- a/messagebus/src/vespa/messagebus/routing/routingnode.cpp
+++ b/messagebus/src/vespa/messagebus/routing/routingnode.cpp
@@ -67,7 +67,7 @@ RoutingNode::~RoutingNode()
void
RoutingNode::clearChildren()
{
- for (auto child : _children) {
+ for (auto * child : _children) {
delete child;
}
_children.clear();
@@ -103,7 +103,7 @@ RoutingNode::prepareForRetry()
clearChildren();
} else if (!_children.empty()) {
bool retryingSome = false;
- for (auto child : _children) {
+ for (auto * child : _children) {
if (child->_shouldRetry || ! child->_reply) {
child->prepareForRetry();
retryingSome = true;
@@ -214,7 +214,7 @@ RoutingNode::notifyAbort(const string &msg)
node->setError(ErrorCode::SEND_ABORTED, msg);
node->notifyParent();
} else {
- for (auto child : node->_children) {
+ for (auto * child : node->_children) {
mystack.push(child);
}
}
@@ -239,7 +239,7 @@ RoutingNode::notifyTransmit()
sendTo.push_back(node);
}
} else {
- for (auto child : node->_children) {
+ for (auto * child : node->_children) {
mystack.push(child);
}
}
@@ -268,7 +268,7 @@ RoutingNode::notifyMerge()
// manipulating the trace in case tracing is disabled.
if (_trace.getLevel() > 0) {
TraceNode tail;
- for (auto child : _children) {
+ for (auto * child : _children) {
TraceNode &root = child->_trace.getRoot();
tail.addChild(root);
root.clear();
@@ -328,7 +328,7 @@ RoutingNode::hasUnconsumedErrors()
}
}
} else {
- for (auto child : node->_children) {
+ for (auto * child : node->_children) {
mystack.push(child);
}
}
@@ -486,7 +486,7 @@ RoutingNode::executePolicySelect()
}
return false;
}
- for (auto child : _children) {
+ for (auto * child : _children) {
Hop &hop = child->_route.getHop(0);
child->_trace.trace(TraceLevel::SPLIT_MERGE,
make_string("Component '%s' selected by policy '%s'.",
@@ -500,7 +500,7 @@ RoutingNode::resolveChildren(uint32_t childDepth)
{
int numActiveChildren = 0;
bool ret = true;
- for (auto child : _children) {
+ for (auto * child : _children) {
child->_trace.trace(TraceLevel::SPLIT_MERGE,
make_string("Resolving '%s'.", child->_route.toString().c_str()));
child->_isActive = ! child->_reply;