Correctly remove tmplink files

Patch by marcuse; reviewed by benedict for CASSANDRA-7803