Change sprintf to snprint in meade.c

https://github.com/Hamlib/Hamlib/issues/857
pull/928/head
Mike Black W9MDB 2022-01-09 11:42:08 -06:00
rodzic 83562939fb
commit d84ac6ab5d
1 zmienionych plików z 2 dodań i 2 usunięć

Wyświetl plik

@ -446,7 +446,7 @@ static const char *meade_get_info(ROT *rot)
struct meade_priv_data *priv = (struct meade_priv_data *)rot->state.priv;
rig_debug(RIG_DEBUG_VERBOSE, "%s called\n", __func__);
sprintf(buf, "Meade telescope rotator with LX200 protocol.\nModel: %s",
snprintf(buf, sizeof(buf), "Meade telescope rotator with LX200 protocol.\nModel: %s",
priv->product_name);
return buf;
}
@ -460,7 +460,7 @@ const struct rot_caps meade_caps =
ROT_MODEL(ROT_MODEL_MEADE),
.model_name = "LX200/Autostar",
.mfg_name = "Meade",
.version = "20200610.0",
.version = "20220109.0",
.copyright = "LGPL",
.status = RIG_STATUS_STABLE,
.rot_type = ROT_TYPE_AZEL,