kopia lustrzana https://github.com/Hamlib/Hamlib
Fix cppcheck warning in usrp_impl.cc
rodzic
abd8b42c2b
commit
b19ae79cd0
|
@ -47,18 +47,12 @@ struct usrp_priv_data {
|
||||||
|
|
||||||
int usrp_init(RIG *rig)
|
int usrp_init(RIG *rig)
|
||||||
{
|
{
|
||||||
struct usrp_priv_data *priv;
|
rig->state.priv = (struct usrp_priv_data*)malloc(sizeof(struct usrp_priv_data));
|
||||||
|
if (!rig->state.priv) {
|
||||||
priv = (struct usrp_priv_data*)malloc(sizeof(struct usrp_priv_data));
|
|
||||||
if (!priv) {
|
|
||||||
/* whoops! memory shortage! */
|
/* whoops! memory shortage! */
|
||||||
return -RIG_ENOMEM;
|
return -RIG_ENOMEM;
|
||||||
}
|
}
|
||||||
|
|
||||||
rig->state.priv = (void*)priv;
|
|
||||||
|
|
||||||
//priv->if_mix_freq = IFMIXFREQ;
|
|
||||||
|
|
||||||
return RIG_OK;
|
return RIG_OK;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Ładowanie…
Reference in New Issue