HDFS-6731. Run 'hdfs zkfc -formatZK' on a server in a non-namenode will cause a null pointer exception. Contributed by Masatake Iwasaki

git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/trunk@1612715 13f79535-47bb-0310-9956-ffa450edef68
YARN-2273. NPE in ContinuousScheduling thread when we lose a node. (Wei Yan via kasha)

git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/trunk@1612720 13f79535-47bb-0310-9956-ffa450edef68