kopia lustrzana https://github.com/Hamlib/Hamlib
Fix bogus sscanf in kpa_get_powerstat -- function would not work
rodzic
731eb39df8
commit
99b7a2da24
|
@ -505,7 +505,7 @@ int kpa_get_powerstat(AMP *amp, powerstat_t *status)
|
|||
int retval;
|
||||
int operate;
|
||||
int ampon;
|
||||
int nargs = sscanf(responsebuf, "^ON%d", &on);
|
||||
int nargs;
|
||||
|
||||
|
||||
rig_debug(RIG_DEBUG_VERBOSE, "%s called\n", __func__);
|
||||
|
@ -518,6 +518,8 @@ int kpa_get_powerstat(AMP *amp, powerstat_t *status)
|
|||
|
||||
if (retval != RIG_OK) { return retval; }
|
||||
|
||||
nargs = sscanf(responsebuf, "^ON%d", &on);
|
||||
|
||||
if (nargs != 1)
|
||||
{
|
||||
rig_debug(RIG_DEBUG_VERBOSE, "%s Error: ^ON response='%s'\n", __func__,
|
||||
|
|
|
@ -65,7 +65,7 @@ const struct amp_caps kpa1500_amp_caps =
|
|||
AMP_MODEL(AMP_MODEL_ELECRAFT_KPA1500),
|
||||
.model_name = "KPA1500",
|
||||
.mfg_name = "Elecraft",
|
||||
.version = "20200112.0",
|
||||
.version = "20210901.0",
|
||||
.copyright = "LGPL",
|
||||
.status = RIG_STATUS_ALPHA,
|
||||
.amp_type = AMP_TYPE_OTHER,
|
||||
|
|
Ładowanie…
Reference in New Issue