 <p>What compiler did you use, I'm willing to bet this worked because whatever compiler you used didn't zero out unused stack variables after a return, you didn't get a seg fault because its still your stack. basically md was left on the stack which you are technically still allowed to address. The difference between the two is </p> <blockquote> <p>largeObj md;</p> </blockquote> <p>is a variable receiving a variable in its entirety.</p> <blockquote> <p>largeObj&amp; mdd = iReturnLargeObjects();</p> </blockquote> <p>is a reference to a variable that due to a lazy compiler still exists.</p>