YARN-1929. Fixed a deadlock in ResourceManager that occurs when failover happens right at the time of shutdown. Contributed by Karthik Kambatla. svn merge --ignore-ancestry -c 1591071 ../../trunk/