Fix frame rate bug after some minutes of runtime.