Fix memory leak that resulted from the concurrent header access fix