mirror of
https://git.rwth-aachen.de/acs/public/villas/node/
synced 2025-03-09 00:00:00 +01:00
ngsi: fix access to signal list in dead-code
Signed-off-by: Steffen Vogel <steffen.vogel@opal-rt.com>
This commit is contained in:
parent
a083488c02
commit
260280ece0
1 changed files with 2 additions and 2 deletions
|
@ -184,9 +184,9 @@ public:
|
|||
json_t *json_value = json_array();
|
||||
|
||||
for (unsigned k = 0; k < cnt; k++) {
|
||||
const auto *sig = (Signal *) list_at_safe(smp->signals, index);
|
||||
const auto *smp = &smps[k];
|
||||
const auto *data = &smp->data[index];
|
||||
auto sig = smp->signals->getByIndex(index);
|
||||
|
||||
json_array_append_new(json_value, json_pack("[ f, o, i ]",
|
||||
time_to_double(smp->ts.origin),
|
||||
|
@ -349,7 +349,7 @@ int ngsi_parse_entity(NodeCompat *n, json_t *json_entity, struct Sample * const
|
|||
smp->ts.origin = tss;
|
||||
|
||||
auto *sd = &smp->data[attr->index];
|
||||
auto *sig = (Signal *) list_at_safe(n->getInputSignals(false), attr->index);
|
||||
auto sig = n->getInputSignals(false)->getByIndex(attr->index);
|
||||
if (!sig)
|
||||
return -11;
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue