debug: Set close-on-exec for the main log file FD