kopia lustrzana https://github.com/Hamlib/Hamlib
Fix mingw compilation errors on new rig_debug macro
rodzic
c3a1b489b7
commit
f88c3f4a4c
|
@ -6556,8 +6556,6 @@ const char *newcat_get_info(RIG *rig)
|
|||
struct newcat_priv_data *priv = (struct newcat_priv_data *)rig->state.priv;
|
||||
static char idbuf[129]; /* extra large static string array */
|
||||
|
||||
ENTERFUNC;
|
||||
|
||||
/* Build the command string */
|
||||
snprintf(priv->cmd_str, sizeof(priv->cmd_str), "ID;");
|
||||
|
||||
|
@ -6566,13 +6564,13 @@ const char *newcat_get_info(RIG *rig)
|
|||
/* Get Identification Channel */
|
||||
if (RIG_OK != newcat_get_cmd(rig))
|
||||
{
|
||||
RETURNFUNC(NULL);
|
||||
return(NULL);
|
||||
}
|
||||
|
||||
priv->ret_data[6] = '\0';
|
||||
snprintf(idbuf, sizeof(idbuf), "%s", priv->ret_data);
|
||||
|
||||
RETURNFUNC(idbuf);
|
||||
return(idbuf);
|
||||
}
|
||||
|
||||
|
||||
|
|
20
src/rig.c
20
src/rig.c
|
@ -366,8 +366,6 @@ RIG *HAMLIB_API rig_init(rig_model_t rig_model)
|
|||
struct rig_state *rs;
|
||||
int i;
|
||||
|
||||
ENTERFUNC;
|
||||
|
||||
rig_check_rig_caps();
|
||||
|
||||
rig_check_backend(rig_model);
|
||||
|
@ -376,7 +374,7 @@ RIG *HAMLIB_API rig_init(rig_model_t rig_model)
|
|||
|
||||
if (!caps)
|
||||
{
|
||||
RETURNFUNC(NULL);
|
||||
return(NULL);
|
||||
}
|
||||
|
||||
/*
|
||||
|
@ -391,7 +389,7 @@ RIG *HAMLIB_API rig_init(rig_model_t rig_model)
|
|||
* FIXME: how can the caller know it's a memory shortage,
|
||||
* and not "rig not found" ?
|
||||
*/
|
||||
RETURNFUNC(NULL);
|
||||
return(NULL);
|
||||
}
|
||||
|
||||
/* caps is const, so we need to tell compiler
|
||||
|
@ -486,7 +484,7 @@ RIG *HAMLIB_API rig_init(rig_model_t rig_model)
|
|||
if (rs->tx_range_list[0].startf == 0)
|
||||
{
|
||||
rig_debug(RIG_DEBUG_ERR, "%s: rig does not have tx_range!!\n", __func__);
|
||||
//RETURNFUNC(NULL); // this is not fatal
|
||||
//return(NULL); // this is not fatal
|
||||
}
|
||||
|
||||
#if 0 // this is no longer applicable -- replace it with something?
|
||||
|
@ -614,11 +612,11 @@ RIG *HAMLIB_API rig_init(rig_model_t rig_model)
|
|||
__func__);
|
||||
/* cleanup and exit */
|
||||
free(rig);
|
||||
RETURNFUNC(NULL);
|
||||
return(NULL);
|
||||
}
|
||||
}
|
||||
|
||||
RETURNFUNC(rig);
|
||||
return(rig);
|
||||
}
|
||||
|
||||
|
||||
|
@ -5736,19 +5734,17 @@ int HAMLIB_API rig_set_vfo_opt(RIG *rig, int status)
|
|||
*/
|
||||
const char *HAMLIB_API rig_get_info(RIG *rig)
|
||||
{
|
||||
ENTERFUNC;
|
||||
|
||||
if (CHECK_RIG_ARG(rig))
|
||||
{
|
||||
RETURNFUNC(NULL);
|
||||
return(NULL);
|
||||
}
|
||||
|
||||
if (rig->caps->get_info == NULL)
|
||||
{
|
||||
RETURNFUNC(NULL);
|
||||
return(NULL);
|
||||
}
|
||||
|
||||
RETURNFUNC(rig->caps->get_info(rig));
|
||||
return(rig->caps->get_info(rig));
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -1091,7 +1091,7 @@ void *handle_socket(void *arg)
|
|||
if (ferror(fsockin))
|
||||
{
|
||||
rig_debug(RIG_DEBUG_ERR, "%s: sockin err=%s\n", __func__, strerror(errno));
|
||||
RETURNFUNC(NULL);
|
||||
return(NULL);
|
||||
}
|
||||
|
||||
#if 0
|
||||
|
|
Ładowanie…
Reference in New Issue