Fixes for doctests under Python 2.6.