Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion lib/nodes/iec61850_goose.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -979,8 +979,14 @@ void GooseNode::parsePublisherData(json_t *json,

auto signal = std::optional<int>{};

if (signal_str)
if (signal_str) {
signal = out.signals->getIndexByName(signal_str);
if (!signal || *signal == -1)
throw RuntimeError("Name not found in output signal section");
}

if (!json_value && !signal_str)
throw RuntimeError("Need either signal name or signal value");

OutputData value = {.signal = signal,
.default_value =
Expand Down
Loading