Moved remove steps to Internal
More refactoring on remove steps
Some workaround for Perl 5.14 memory leaks
Use common remove code