Made $log_fd a static var so it would propagate through classes