New code for 2.6 branch merge