Clean up preview images on upload errors (bug 1051854)

Good question, copy-pasted from the test above is not a valid answer I presume :)