Fix freeing gl buffers on the simulator.