Correctly report errors.

Doh!

Change-Id: Ia9b0b37accd515fdeeac80d3cc5567f5b6c15d0b