Skip to content

Commit

Permalink
avoid logging loop when LOG_PACKET_TYPE is enabled
Browse files Browse the repository at this point in the history
  • Loading branch information
totaam committed Jan 14, 2025
1 parent 12af226 commit 42d7116
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion xpra/client/mixins/logging.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
from xpra.util.str_fn import csv, repr_ellipsized
from xpra.client.base.stub_client_mixin import StubClientMixin
from xpra.log import Logger, set_global_logging_handler
from xpra.net.common import PacketType
from xpra.net.common import PacketType, LOG_PACKET_TYPE
from xpra.net.compression import Compressed

log = Logger("client")
Expand Down Expand Up @@ -63,6 +63,10 @@ def parse_server_capabilities(self, c: typedict) -> bool:
log.warn("Warning: cannot enable remote logging")
log.warn(" because debug logging is enabled for: %s", csv(conflict))
return True
if LOG_PACKET_TYPE:
log.warn("Warning: cannot enable remote logging")
log.warn(f" because {LOG_PACKET_TYPE=}")
return True
log.info("enabled remote logging")
if not self.log_both:
log.info(" see server log file for further output")
Expand Down

0 comments on commit 42d7116

Please sign in to comment.