fix search leaks