mirror of
https://github.com/xcat2/confluent.git
synced 2024-11-22 09:32:21 +00:00
Fix collective name return
It inadvertently would return None when rereading from file.
This commit is contained in:
parent
a3bd21d605
commit
7cfdf11bf2
@ -204,7 +204,7 @@ def get_myname():
|
||||
with open('/etc/confluent/cfg/myname', 'r') as f:
|
||||
mycachedname[0] = f.read().strip()
|
||||
mycachedname[1] = time.time()
|
||||
return
|
||||
return mycachedname[0]
|
||||
except IOError:
|
||||
myname = socket.gethostname()
|
||||
with open('/etc/confluent/cfg/myname', 'w') as f:
|
||||
|
Loading…
Reference in New Issue
Block a user