diff options
author | Yury Selivanov <yselivanov@sprymix.com> | 2015-12-11 16:32:59 (GMT) |
---|---|---|
committer | Yury Selivanov <yselivanov@sprymix.com> | 2015-12-11 16:32:59 (GMT) |
commit | dddc781998da741511178c7cb4e303e3db5aac45 (patch) | |
tree | 3953a4a1870e3761a1bd82cc42f8901f942eccc7 /Lib/asyncio/streams.py | |
parent | 5e58600c42137cbf17938c7035ea5d41b3e860f6 (diff) | |
download | cpython-dddc781998da741511178c7cb4e303e3db5aac45.zip cpython-dddc781998da741511178c7cb4e303e3db5aac45.tar.gz cpython-dddc781998da741511178c7cb4e303e3db5aac45.tar.bz2 |
asyncio: Sync with github
Diffstat (limited to 'Lib/asyncio/streams.py')
-rw-r--r-- | Lib/asyncio/streams.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/Lib/asyncio/streams.py b/Lib/asyncio/streams.py index 6b5e96a..9097e38 100644 --- a/Lib/asyncio/streams.py +++ b/Lib/asyncio/streams.py @@ -494,6 +494,9 @@ class StreamReader: @coroutine def readexactly(self, n): + if n < 0: + raise ValueError('readexactly size can not be less than zero') + if self._exception is not None: raise self._exception |