fix error propagation in dds_get_qos
Signed-off-by: Erik Boasson <eb@ilities.com>
This commit is contained in:
parent
9f51c44e50
commit
65ac9b0711
1 changed files with 3 additions and 4 deletions
|
@ -560,7 +560,7 @@ dds_get_qos(
|
||||||
{
|
{
|
||||||
dds_entity *e;
|
dds_entity *e;
|
||||||
dds__retcode_t rc;
|
dds__retcode_t rc;
|
||||||
dds_return_t ret = DDS_RETCODE_OK;
|
dds_return_t ret;
|
||||||
|
|
||||||
if (qos == NULL) {
|
if (qos == NULL) {
|
||||||
DDS_ERROR("Argument qos is NULL\n");
|
DDS_ERROR("Argument qos is NULL\n");
|
||||||
|
@ -574,11 +574,10 @@ dds_get_qos(
|
||||||
goto fail;
|
goto fail;
|
||||||
}
|
}
|
||||||
if (e->m_deriver.set_qos) {
|
if (e->m_deriver.set_qos) {
|
||||||
rc = dds_copy_qos(qos, e->m_qos);
|
ret = dds_copy_qos(qos, e->m_qos);
|
||||||
} else {
|
} else {
|
||||||
rc = DDS_RETCODE_ILLEGAL_OPERATION;
|
|
||||||
DDS_ERROR("QoS cannot be set on this entity\n");
|
DDS_ERROR("QoS cannot be set on this entity\n");
|
||||||
ret = DDS_ERRNO(rc);
|
ret = DDS_ERRNO(DDS_RETCODE_ILLEGAL_OPERATION);
|
||||||
}
|
}
|
||||||
dds_entity_unlock(e);
|
dds_entity_unlock(e);
|
||||||
fail:
|
fail:
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue