From 29a80fb496696fb40a93e022987371da5c1d68db Mon Sep 17 00:00:00 2001 From: Mike Black W9MDB Date: Fri, 13 Jan 2023 17:30:55 -0600 Subject: [PATCH] Fix get_powerstat call when get_powerstat is not defined https://github.com/Hamlib/Hamlib/issues/1217 --- NEWS | 1 + tests/rigctl_parse.c | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/NEWS b/NEWS index 996d795cb..e05a27468 100644 --- a/NEWS +++ b/NEWS @@ -25,6 +25,7 @@ Version 4.6 * Fix FTDX3000 rig split Version 4.5.5 + * Fix get_powerstat bad call in rigctl_parse.c * Really fix CM108 ptt_bitnum usage * Fix Elecraft power2mW precision/accuracy * Fix power on/off/on for Icom rigs with rigctld power_on=0 diff --git a/tests/rigctl_parse.c b/tests/rigctl_parse.c index c1aeb8388..c1c0dc8a4 100644 --- a/tests/rigctl_parse.c +++ b/tests/rigctl_parse.c @@ -1731,7 +1731,7 @@ readline_repeat: else { - if (my_rig->caps->set_powerstat && (rig_powerstat == RIG_POWER_OFF + if (my_rig->caps->get_powerstat && (rig_powerstat == RIG_POWER_OFF || rig_powerstat == RIG_POWER_STANDBY)) { // Update power status