tar-in: Fix places where we didn't cancel the receive (FileIn) correctly along error paths (RHBZ#1091803).

Thanks: Bo Fan.
Add a regression test for RHBZ#1091803.