Skip to content

Commit

Permalink
Changing the loop condition to halt at the first match in the propert…
Browse files Browse the repository at this point in the history
…y list for RpcEnv exception catch
  • Loading branch information
Harsh Gupta authored and Harsh Gupta committed May 21, 2015
1 parent f74064d commit 0ee5642
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion core/src/main/scala/org/apache/spark/rpc/RpcEnv.scala
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,7 @@ object RpcTimeout {
// Find the first set property or use the default value with the first property
val itr = timeoutPropList.iterator
var foundProp = (timeoutPropList.head,defaultValue)
while (itr.hasNext){
while (itr.hasNext && (foundProp == (timeoutPropList.head,defaultValue))){
val propKey = itr.next()
conf.getOption(propKey) match {
case Some(prop) => foundProp = (propKey,prop)
Expand Down

0 comments on commit 0ee5642

Please sign in to comment.