Fix handling for invalid or missing app images am: 6b689ceb63
am: a3ae539b9f

Change-Id: I6c5ed07c6686a94a6eeed4ea908be3facb0a009e