diff options
author | Mark Dickinson <dickinsm@gmail.com> | 2010-01-01 17:27:30 +0000 |
---|---|---|
committer | Mark Dickinson <dickinsm@gmail.com> | 2010-01-01 17:27:30 +0000 |
commit | 3e177ab0b393a415c36f5fc41012f59fff5860fb (patch) | |
tree | 1b6706772fbcdd8171857ee5ca29c1d822d54d42 /Lib/os.py | |
parent | 6e75924b2380786cde6accd94fe1a3a740625df0 (diff) | |
download | cpython-3e177ab0b393a415c36f5fc41012f59fff5860fb.tar.gz |
Issue #5080: turn the DeprecationWarning from float arguments passed
to integer PyArg_Parse* format codes into a TypeError. Add a
DeprecationWarning for floats passed with the 'L' format code, which
didn't previously have a warning.
Diffstat (limited to 'Lib/os.py')
-rw-r--r-- | Lib/os.py | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -752,7 +752,7 @@ if not _exists("urandom"): raise NotImplementedError("/dev/urandom (or equivalent) not found") try: bs = b"" - while n - len(bs) >= 1: + while n > len(bs): bs += read(_urandomfd, n - len(bs)) finally: close(_urandomfd) |