diff --git a/apps/aqhome-react/types/unit.c b/apps/aqhome-react/types/unit.c index 0deee87..cf64dff 100644 --- a/apps/aqhome-react/types/unit.c +++ b/apps/aqhome-react/types/unit.c @@ -490,7 +490,7 @@ void AQHREACT_Unit_OutputData(AQHREACT_UNIT *unit, AQHREACT_PORT *port, const AQ void AQHREACT_Unit_OutputDoubleData(AQHREACT_UNIT *unit, AQHREACT_PORT *port, double data) { - if (unit && unit->outputPortList) { + if (unit && port && unit->outputPortList) { AQHREACT_DATAOBJECT *dataObject; dataObject=AQHREACT_DataObject_new(); @@ -505,7 +505,7 @@ void AQHREACT_Unit_OutputDoubleData(AQHREACT_UNIT *unit, AQHREACT_PORT *port, do void AQHREACT_Unit_OutputStringData(AQHREACT_UNIT *unit, AQHREACT_PORT *port, const char *data) { - if (unit && unit->outputPortList) { + if (unit && port && unit->outputPortList) { AQHREACT_DATAOBJECT *dataObject; dataObject=AQHREACT_DataObject_new();