More string null tests.
Close the fd properly and add a bad domain test.