Make some modifications to TSFHandler

- Remove unnecessary activation of TSF
- Fix a possible null dereference
- Uninstall an installed advice sink to avoid a resource leak