Fixes a thread leak in FMJ.