Fix reboot loop due to NPE. am: 6e24ec7ff6

Original change: undetermined

Change-Id: Ie6d8cdc24bddc0553494f7373f6ac03ca68e8313