Fix leaked globals.