Serhiy Storchaka added the comment:

PyLong_AsLong() not just converts Python integer to C long, but it also 
converts Python float to Python integer (with the lost of the fractional part). 
We need to check that the value is Python integer.

Here is a patch that fixes this issue and few other bugs.

----------
nosy: +serhiy.storchaka
stage: commit review -> patch review
versions:  -Python 3.3, Python 3.4
Added file: 
http://bugs.python.org/file44471/itertools_count_truncated_step.patch

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28019>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to