Cleared potential gpu memory leaks