cleanly closed serial port