Some simple bug fixes and 2.6 compatibility support