updated commander
authorMarius Sandu-Popa <sandupopamarius@gmail.com>
Fri, 5 Feb 2010 20:04:42 +0000 (22:04 +0200)
committerMarius Sandu-Popa <sandupopamarius@gmail.com>
Fri, 5 Feb 2010 20:04:58 +0000 (22:04 +0200)
bt_comm/client/Client.py

index 57c3e1f..02719f3 100644 (file)
@@ -90,13 +90,20 @@ class Commander(Thread):
                node = self.nodes.getNodeBySi(si)
                base_path = node.getClientBaseDir(si.btclient)
                torrent_file = self.swarm.getTorrentFile()
-               config_data = [{'client':si.btclient, 
-                                       'base_path':base_path, 
-                                       'download_dir':si.download_dir, 
-                                       'log_dir':si.log_dir, 
-                                       'torrent_file':torrent_file, 
-                                       'output_dir':si.output_dir, }]
-               self.printDummyCommand(node.public_address, node.public_port, START_MSG, config_data)
+               
+               config_data = {CLIENT : si.btclient, 
+                                       BASE_DIR : base_path, 
+                                       UP_LIMIT : si.download_limit,
+                                       DL_LIMIT : si.upload_limit,
+                                       PORT : node.public_port,
+                                       DL_DIR : si.download_dir, 
+                                       LOG_DIR : si.log_dir, 
+                                       OUT_FILE : si.output_file,
+                                       LOG_FILE : si.log_file,
+                                       TORRENT : torrent_file
+                                       }
+               
+               self.printDummyCommand(node.public_address, node.listen_port, START_MSG, config_data)
                #sendComm(node.public_address, node.public_port, START_MSG, config_data)
        
        def printDummyCommand(self, public_address, public_port, option1, data):