channels: patch rdpdr/smartcard valgrind leaks, fix hang on disconnect