Fixed Python2.6 incompatibility caused by 67c30426c1370f5d6c39bd73888c3902c1c5f365.