def maybe_write():
    if (not self._transport):
        return
    if (hasattr(self._transport, 'is_closing') and self._transport.is_closing()):
        return
    self._transport.write(tmsg)
def maybe_write():
    if (not self._transport):
        return
    if (hasattr(self._transport, 'is_closing') and self._transport.is_closing()):
        return
    self._transport.write(tmsg)