mirror of
https://git.deluge-torrent.org/deluge
synced 2025-08-23 19:03:23 +00:00
Fix #1945 : Mutable default arguments in deluge.ui.client
This commit is contained in:
parent
cade8ee784
commit
3a0b6f8a6d
1 changed files with 20 additions and 16 deletions
|
@ -17,9 +17,9 @@
|
|||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with deluge. If not, write to:
|
||||
# The Free Software Foundation, Inc.,
|
||||
# 51 Franklin Street, Fifth Floor
|
||||
# Boston, MA 02110-1301, USA.
|
||||
# The Free Software Foundation, Inc.,
|
||||
# 51 Franklin Street, Fifth Floor
|
||||
# Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# In addition, as a special exception, the copyright holders give
|
||||
# permission to link the code of portions of this program with the OpenSSL
|
||||
|
@ -240,7 +240,9 @@ class DaemonProxy(object):
|
|||
pass
|
||||
|
||||
class DaemonSSLProxy(DaemonProxy):
|
||||
def __init__(self, event_handlers={}):
|
||||
def __init__(self, event_handlers=None):
|
||||
if event_handlers is None:
|
||||
event_handlers = {}
|
||||
self.__factory = DelugeRPCClientFactory(self, event_handlers)
|
||||
self.__request_counter = 0
|
||||
self.__deferred = {}
|
||||
|
@ -427,7 +429,9 @@ class DaemonSSLProxy(DaemonProxy):
|
|||
return self.__factory.bytes_sent
|
||||
|
||||
class DaemonClassicProxy(DaemonProxy):
|
||||
def __init__(self, event_handlers={}):
|
||||
def __init__(self, event_handlers=None):
|
||||
if event_handlers is None:
|
||||
event_handlers = {}
|
||||
import deluge.core.daemon
|
||||
self.__daemon = deluge.core.daemon.Daemon(classic=True)
|
||||
log.debug("daemon created!")
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue