From: Guido van Rossum Date: Sun, 18 Mar 2007 03:36:28 +0000 (+0000) Subject: Bug 1679498: unset variable 'bs'. X-Git-Tag: v3.0a1~1120 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=bb09b212505a70a2b9f43ee2df6dd3ddb09776c1;p=python Bug 1679498: unset variable 'bs'. --- diff --git a/Lib/io.py b/Lib/io.py index e4e6759687..59c4b06234 100644 --- a/Lib/io.py +++ b/Lib/io.py @@ -91,6 +91,8 @@ def open(filename, mode="r", buffering=None, *, encoding=None): try: bs = os.fstat(raw.fileno()).st_blksize except (os.error, AttributeError): + pass + else: if bs > 1: buffering = bs if buffering < 0: