kopia lustrzana https://github.com/Hamlib/Hamlib
Fix cppcheck warning in racal.c
rodzic
a88c53b4ad
commit
9ce5a51a05
|
@ -128,15 +128,15 @@ int racal_init(RIG *rig)
|
|||
return -RIG_EINVAL;
|
||||
}
|
||||
|
||||
priv = (struct racal_priv_data *)malloc(sizeof(struct racal_priv_data));
|
||||
rig->state.priv = (struct racal_priv_data *)malloc(sizeof(struct racal_priv_data));
|
||||
|
||||
if (!priv)
|
||||
if (!rig->state.priv)
|
||||
{
|
||||
/* whoops! memory shortage! */
|
||||
return -RIG_ENOMEM;
|
||||
}
|
||||
|
||||
rig->state.priv = (void *)priv;
|
||||
priv = rig->state.priv;
|
||||
|
||||
priv->receiver_id = 0;
|
||||
priv->bfo = 0;
|
||||
|
|
Ładowanie…
Reference in New Issue