prepareForLeakDetection