fixed handling of invalid image data in AssetLoader (closes #563)