bugfix: close forgotten file descriptors