def __init__(self, fname, handler): self.log = logging.getLogger('qtile') self.fname = fname self.handler = handler self.loop = asyncio.get_event_loop() if os.path.exists(fname): os.unlink(fname) self.sock = socket.socket(socket.AF_UNIX, socket.SOCK_STREAM, 0) flags = fcntl.fcntl(self.sock, fcntl.F_GETFD) fcntl.fcntl(self.sock, fcntl.F_SETFD, flags | fcntl.FD_CLOEXEC) self.sock.bind(self.fname)
def __init__(self, fname, handler): self.log = logging.getLogger("qtile") self.fname = fname self.handler = handler self.loop = asyncio.get_event_loop() if os.path.exists(fname): os.unlink(fname) self.sock = socket.socket(socket.AF_UNIX, socket.SOCK_STREAM, 0) flags = fcntl.fcntl(self.sock, fcntl.F_GETFD) fcntl.fcntl(self.sock, fcntl.F_SETFD, flags | fcntl.FD_CLOEXEC) self.sock.bind(self.fname)
def __init__(self, fname): self.fname = fname self.loop = asyncio.get_event_loop()
def __init__(self, fname, is_json=False): self.fname = fname self.loop = asyncio.get_event_loop() self.is_json = is_json