mirror of
https://github.com/haiwen/ccnet-server.git
synced 2025-08-11 17:31:39 +00:00
Merge pull request #1 from haiwen/fix-read-port-conf
Fix reading port in ccnet python module.
This commit is contained in:
commit
d00e87b092
@ -91,7 +91,10 @@ class Client(object):
|
|||||||
def parse_config(self):
|
def parse_config(self):
|
||||||
self.config = ConfigParser.ConfigParser()
|
self.config = ConfigParser.ConfigParser()
|
||||||
self.config.read(self.config_file)
|
self.config.read(self.config_file)
|
||||||
|
if self.config.has_option('Client', 'PORT'):
|
||||||
self.port = self.config.getint('Client', 'PORT')
|
self.port = self.config.getint('Client', 'PORT')
|
||||||
|
else:
|
||||||
|
self.port = 10001
|
||||||
self.un_path = ''
|
self.un_path = ''
|
||||||
if self.config.has_option('Client', 'UNIX_SOCKET'):
|
if self.config.has_option('Client', 'UNIX_SOCKET'):
|
||||||
self.un_path = self.config.get('Client', 'UNIX_SOCKET')
|
self.un_path = self.config.get('Client', 'UNIX_SOCKET')
|
||||||
|
Loading…
Reference in New Issue
Block a user