All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] cec-ctl: print correct destination address for broadcast msgs
@ 2016-08-24 10:24 Johan Fjeldtvedt
  0 siblings, 0 replies; only message in thread
From: Johan Fjeldtvedt @ 2016-08-24 10:24 UTC (permalink / raw)
  To: linux-media; +Cc: Johan Fjeldtvedt

When messages are broadcast, it is not necessary to supply a --to option
to cec-ctl, but in that case the destination address was printed wrongly.

Signed-off-by: Johan Fjeldtvedt <jaffe1@gmail.com>
---
 utils/cec-ctl/cec-ctl.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/utils/cec-ctl/cec-ctl.cpp b/utils/cec-ctl/cec-ctl.cpp
index 10efcbd..9db6299 100644
--- a/utils/cec-ctl/cec-ctl.cpp
+++ b/utils/cec-ctl/cec-ctl.cpp
@@ -1888,7 +1888,7 @@ int main(int argc, char **argv)
 		}
 		printf("\nTransmit from %s to %s (%d to %d):\n", la2s(from),
 		       (cec_msg_is_broadcast(&msg) || to == 0xf) ? "all" : la2s(to),
-		       from, to);
+		       from, cec_msg_is_broadcast(&msg) ? 0xf : to);
 		msg.msg[0] |= (from << 4) | (cec_msg_is_broadcast(&msg) ? 0xf : to);
 		log_msg(&msg);
 		if (doioctl(&node, CEC_TRANSMIT, &msg))
-- 
2.7.4


^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2016-08-24 10:24 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-08-24 10:24 [PATCH] cec-ctl: print correct destination address for broadcast msgs Johan Fjeldtvedt

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.