Fixed issue on xrange.