Add comment to is_read_cmd newcat.c and remove redundant check

https://github.com/Hamlib/Hamlib/issues/385
This commit is contained in:
Michael Black W9MDB 2020-09-26 22:34:02 -05:00
parent 60201aab40
commit 359f7549dc

View File

@ -6484,6 +6484,7 @@ int newcat_get_cmd(RIG *rig)
// we drop through and do the real IF command
}
// any command that is read only should not expire cache
is_read_cmd =
strcmp(priv->cmd_str,"AG0;")==0
|| strcmp(priv->cmd_str,"AG1;")==0
@ -6533,8 +6534,7 @@ int newcat_get_cmd(RIG *rig)
|| strcmp(priv->cmd_str,"SQ0;")==0
|| strcmp(priv->cmd_str,"SQ1;")==0
|| strcmp(priv->cmd_str,"VT0;")==0
|| strcmp(priv->cmd_str,"VT1;")==0
|| strcmp(priv->cmd_str,"SQ1;")==0;
|| strcmp(priv->cmd_str,"VT1;")==0;
if (priv->cmd_str[2] !=
';' && !is_read_cmd) // then we must be setting something so we'll invalidate the cache