瀏覽代碼

make it possible to pass a custom map to asyncore.dispatcher via asynchat

Chris McDonough 11 年之前
父節點
當前提交
4e2046e317
共有 1 個文件被更改,包括 2 次插入2 次删除
  1. 2 2
      supervisor/medusa/asynchat_25.py

+ 2 - 2
supervisor/medusa/asynchat_25.py

@@ -59,11 +59,11 @@ class async_chat (asyncore.dispatcher):
     ac_in_buffer_size       = 4096
     ac_out_buffer_size      = 4096
 
-    def __init__ (self, conn=None):
+    def __init__ (self, conn=None, map=None):
         self.ac_in_buffer = ''
         self.ac_out_buffer = ''
         self.producer_fifo = fifo()
-        asyncore.dispatcher.__init__ (self, conn)
+        asyncore.dispatcher.__init__ (self, conn, map)
 
     def collect_incoming_data(self, data):
         raise NotImplementedError("must be implemented in subclass")