Fix rig_caps_get_int to use long long instead of enum

enum was coming out as 32-bit instead of 64-bit
https://github.com/Hamlib/Hamlib/issues/562
pull/573/head
Michael Black W9MDB 2021-02-26 15:00:15 -06:00
rodzic 9d714e639c
commit 8ccc9f0737
1 zmienionych plików z 3 dodań i 3 usunięć

Wyświetl plik

@ -2146,7 +2146,7 @@ void *rig_get_function_ptr(rig_model_t rig_model,
* \param RIG* and rig_caps_int_e
* \return the corresponding long value -- -RIG_EINVAL is the only error possible
*/
long long rig_get_caps_int(rig_model_t rig_model, enum rig_caps_int_e rig_caps)
long long rig_get_caps_int(rig_model_t rig_model, long long rig_caps)
{
const struct rig_caps *caps = rig_get_caps(rig_model);
@ -2168,8 +2168,8 @@ long long rig_get_caps_int(rig_model_t rig_model, enum rig_caps_int_e rig_caps)
return caps->has_get_level;
default:
rig_debug(RIG_DEBUG_ERR, "%s: Unknown rig_caps value=%d\n", __func__, rig_caps);
return -RIG_EINVAL;
//rig_debug(RIG_DEBUG_ERR, "%s: Unknown rig_caps value=%lld\n", __func__, rig_caps);
RETURNFUNC(-RIG_EINVAL);
}
}