Added cleanup and copy functions for fd tables.