Home » Microsoft » 70-573 » Which code segment should you add?
You have a Web application that contains the following code segment.
You need to prevent the code segment from causing a memory leak.
Which code segment should you add?
A.
B.
C. siteCollection = null;
D. siteCollection.WriteLocked = false;
Correct Answer: B
Explanation/Reference:
MNEMONIC RULE: "Dispose of memory leak"
Difference between Close() and Dispose() Method http://dotnetguts.blogspot.com/2007/06/difference-between-close-and-dispose.html