MCPcopy Create free account
hub / github.com/Hamlib/Hamlib / rig_has_ext_token

Function rig_has_ext_token

src/ext.c:46–67  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

44#include "token.h"
45
46static int rig_has_ext_token(RIG *rig, hamlib_token_t token)
47{
48 const int *ext_tokens = rig->caps->ext_tokens;
49 int i;
50
51 if (ext_tokens == NULL)
52 {
53 // Assume that all listed extfuncs/extlevels/extparms are supported if
54 // the ext_tokens list is not defined to preserve backwards-compatibility
55 return 1;
56 }
57
58 for (i = 0; ext_tokens[i] != TOK_BACKEND_NONE; i++)
59 {
60 if (ext_tokens[i] == token)
61 {
62 return 1;
63 }
64 }
65
66 return 0;
67}
68
69
70/**

Callers 3

rig_ext_func_foreachFunction · 0.85
rig_ext_level_foreachFunction · 0.85
rig_ext_parm_foreachFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected