[issue4537] webbrowser.UnixBrowser should use builtins.open

gumpy report at bugs.python.org
Fri Dec 5 00:51:44 CET 2008


gumpy <gumpy2k7 at gmail.com> added the comment:

I'd suggest the same thing that was done on lines 351-352.

Index: Lib/webbrowser.py
===================================================================
--- Lib/webbrowser.py	(revision 67538)
+++ Lib/webbrowser.py	(working copy)
@@ -223,7 +223,8 @@
         cmdline = [self.name] + raise_opt + args
 
         if remote or self.background:
-            inout = open(os.devnull, "r+")
+            import io
+            inout = io.open(os.devnull, "r+")
         else:
             # for TTY browsers, we need stdin/out
             inout = None

----------
nosy: +gumpy

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue4537>
_______________________________________


More information about the Python-bugs-list mailing list