From: Amaury Forgeot d'Arc Date: Mon, 12 May 2008 14:41:00 +0000 (+0000) Subject: #Issue2835: Correct an infinite recursion in webbrowser.open(), when KDE Konqueror... X-Git-Tag: v3.0b1~369 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=2b2b44dc2c2b95569e0e59c6dd4b12148ffba598;p=python #Issue2835: Correct an infinite recursion in webbrowser.open(), when KDE Konqueror is tried. --- diff --git a/Lib/webbrowser.py b/Lib/webbrowser.py index a028df0cf6..4772adc6c0 100644 --- a/Lib/webbrowser.py +++ b/Lib/webbrowser.py @@ -347,7 +347,8 @@ class Konqueror(BaseBrowser): else: action = "openURL" - devnull = open(os.devnull, "r+") + import io + devnull = io.open(os.devnull, "r+") # if possible, put browser in separate process group, so # keyboard interrupts don't affect browser as well as Python setsid = getattr(os, 'setsid', None) diff --git a/Misc/NEWS b/Misc/NEWS index e40844e726..3f0b4a935a 100644 --- a/Misc/NEWS +++ b/Misc/NEWS @@ -25,6 +25,8 @@ Extension Modules Library ------- +- Issue 2865: webbrowser.open() works again in a KDE environment. + - The multifile module has been removed. - The SocketServer module has been renamed to socketserver.