diff --git a/src/core/ddsc/src/dds_entity.c b/src/core/ddsc/src/dds_entity.c index 6704b6e..7d62349 100644 --- a/src/core/ddsc/src/dds_entity.c +++ b/src/core/ddsc/src/dds_entity.c @@ -269,8 +269,8 @@ dds_return_t dds_delete_impl (dds_entity_t entity, bool keep_if_explicit) dds_free (e); } - return ret; - } + return ret; +} dds_entity_t dds_get_parent (dds_entity_t entity) { @@ -404,11 +404,9 @@ dds_return_t dds_get_listener (dds_entity_t entity, dds_listener_t *listener) ddsrt_mutex_unlock (&e->m_observers_lock); dds_entity_unlock(e); } else { - DDS_ERROR("Error occurred on locking entity\n"); ret = DDS_ERRNO(rc); } } else { - DDS_ERROR("Argument listener is NULL\n"); ret = DDS_ERRNO(DDS_RETCODE_BAD_PARAMETER); } diff --git a/src/core/ddsc/src/dds_instance.c b/src/core/ddsc/src/dds_instance.c index 5d15275..25156fe 100644 --- a/src/core/ddsc/src/dds_instance.c +++ b/src/core/ddsc/src/dds_instance.c @@ -134,18 +134,15 @@ dds_register_instance( dds_retcode_t rc; if(data == NULL){ - DDS_ERROR("Argument data is NULL\n"); ret = DDS_ERRNO(DDS_RETCODE_BAD_PARAMETER); goto err; } if(handle == NULL){ - DDS_ERROR("Argument handle is NULL\n"); ret = DDS_ERRNO(DDS_RETCODE_BAD_PARAMETER); goto err; } rc = dds_writer_lock(writer, &wr); if (rc != DDS_RETCODE_OK) { - DDS_ERROR("Error occurred on locking writer\n"); ret = DDS_ERRNO(rc); goto err; } @@ -155,7 +152,6 @@ dds_register_instance( *handle = inst->m_iid; ret = DDS_RETCODE_OK; } else { - DDS_ERROR("Unable to create instance\n"); ret = DDS_ERRNO(DDS_RETCODE_ERROR); } thread_state_asleep (ts1); @@ -194,19 +190,16 @@ dds_unregister_instance_ts( dds_writer *wr; if (data == NULL){ - DDS_ERROR("Argument data is NULL\n"); ret = DDS_ERRNO(DDS_RETCODE_BAD_PARAMETER); goto err; } if(timestamp < 0){ - DDS_ERROR("Argument timestamp has negative value\n"); ret = DDS_ERRNO(DDS_RETCODE_BAD_PARAMETER); goto err; } rc = dds_writer_lock(writer, &wr); if (rc != DDS_RETCODE_OK) { - DDS_ERROR("Error occurred on locking writer\n"); - ret = DDS_ERRNO(rc); + ret = DDS_ERRNO(rc); goto err; } @@ -241,7 +234,6 @@ dds_unregister_instance_ih_ts( rc = dds_writer_lock(writer, &wr); if (rc != DDS_RETCODE_OK) { - DDS_ERROR("Error occurred on locking writer\n"); ret = DDS_ERRNO(rc); goto err; } @@ -264,7 +256,6 @@ dds_unregister_instance_ih_ts( ret = dds_write_impl (wr, sample, timestamp, action); ddsi_sertopic_free_sample (tp, sample, DDS_FREE_ALL); } else { - DDS_ERROR("No instance related with the provided handle is found\n"); ret = DDS_ERRNO(DDS_RETCODE_PRECONDITION_NOT_MET); } thread_state_asleep (ts1); @@ -294,7 +285,6 @@ dds_writedispose_ts( thread_state_asleep (ts1); dds_writer_unlock(wr); } else { - DDS_ERROR("Error occurred on locking writer\n"); ret = DDS_ERRNO(rc); } @@ -336,7 +326,6 @@ dds_dispose_ts( thread_state_asleep (ts1); dds_writer_unlock(wr); } else { - DDS_ERROR("Error occurred on locking writer\n"); ret = DDS_ERRNO(rc); } @@ -366,13 +355,11 @@ dds_dispose_ih_ts( ret = dds_dispose_impl (wr, sample, handle, timestamp); ddsi_sertopic_free_sample (tp, sample, DDS_FREE_ALL); } else { - DDS_ERROR("No instance related with the provided handle is found\n"); ret = DDS_ERRNO(DDS_RETCODE_PRECONDITION_NOT_MET); } thread_state_asleep (ts1); dds_writer_unlock(wr); } else { - DDS_ERROR("Error occurred on locking writer\n"); ret = DDS_ERRNO(rc); } @@ -391,7 +378,6 @@ dds_lookup_instance( struct ddsi_serdata *sd; if(data == NULL){ - DDS_ERROR("Argument data is NULL\n"); goto err; } @@ -402,8 +388,6 @@ dds_lookup_instance( ih = ddsi_tkmap_lookup (map, sd); ddsi_serdata_unref (sd); thread_state_asleep (ts1); - } else { - DDS_ERROR("Acquired topic is NULL\n"); } err: return ih; @@ -429,14 +413,12 @@ dds_instance_get_key( struct ddsi_tkmap_instance * tk; if(data == NULL){ - DDS_ERROR("Argument data is NULL\n"); ret = DDS_ERRNO(DDS_RETCODE_BAD_PARAMETER); goto err; } topic = dds_instance_info_by_hdl (entity); if(topic == NULL){ - DDS_ERROR("Could not find topic related to the given entity\n"); ret = DDS_ERRNO(DDS_RETCODE_BAD_PARAMETER); goto err; } @@ -447,7 +429,6 @@ dds_instance_get_key( ddsi_tkmap_instance_unref (tk); ret = DDS_RETCODE_OK; } else { - DDS_ERROR("No instance related with the provided entity is found\n"); ret = DDS_ERRNO(DDS_RETCODE_BAD_PARAMETER); } thread_state_asleep (ts1); diff --git a/src/core/ddsc/src/dds_participant.c b/src/core/ddsc/src/dds_participant.c index 587951a..a0c3c03 100644 --- a/src/core/ddsc/src/dds_participant.c +++ b/src/core/ddsc/src/dds_participant.c @@ -37,7 +37,6 @@ dds_participant_status_validate( dds_return_t ret = DDS_RETCODE_OK; if (mask & ~(DDS_PARTICIPANT_STATUS_MASK)) { - DDS_ERROR("Argument mask is invalid\n"); ret = DDS_ERRNO(DDS_RETCODE_BAD_PARAMETER); } diff --git a/src/core/ddsc/src/dds_read.c b/src/core/ddsc/src/dds_read.c index d595272..5be40d1 100644 --- a/src/core/ddsc/src/dds_read.c +++ b/src/core/ddsc/src/dds_read.c @@ -123,7 +123,6 @@ dds_read_impl( thread_state_awake (ts1); rc = dds_read_lock(reader_or_condition, &rd, &cond, only_reader); if (rc != DDS_RETCODE_OK) { - DDS_ERROR("Error occurred on locking entity\n"); ret = DDS_ERRNO(rc); goto fail_awake; } @@ -223,7 +222,6 @@ dds_readcdr_impl( } dds_read_unlock(rd, cond); } else { - DDS_ERROR("Error occurred on locking entity\n"); ret = DDS_ERRNO(rc); } @@ -695,7 +693,6 @@ dds_return_loan( rc = dds_read_lock(reader_or_condition, &rd, &cond, false); if (rc != DDS_RETCODE_OK) { - DDS_ERROR("Error occurred on locking entity\n"); ret = DDS_ERRNO(rc); goto fail; } diff --git a/src/core/ddsc/src/dds_topic.c b/src/core/ddsc/src/dds_topic.c index 636c4ae..5d62fdf 100644 --- a/src/core/ddsc/src/dds_topic.c +++ b/src/core/ddsc/src/dds_topic.c @@ -200,7 +200,6 @@ dds_find_topic( ddsrt_mutex_unlock (&dds_global.m_mutex); dds_entity_unlock(p); } else { - DDS_ERROR("Error occurred on locking entity\n"); tp = DDS_ERRNO(rc); } } else { @@ -334,7 +333,6 @@ dds_create_topic_arbitrary ( rc = dds_entity_lock(participant, DDS_KIND_PARTICIPANT, &par); if (rc != DDS_RETCODE_OK) { - DDS_ERROR("Error occurred on locking entity\n"); hdl = DDS_ERRNO(rc); goto lock_err; } diff --git a/src/core/ddsc/src/dds_waitset.c b/src/core/ddsc/src/dds_waitset.c index 787ce2c..4d5bd4b 100644 --- a/src/core/ddsc/src/dds_waitset.c +++ b/src/core/ddsc/src/dds_waitset.c @@ -217,7 +217,6 @@ dds_create_waitset( waitset->triggered = NULL; dds_entity_unlock(par); } else { - DDS_ERROR("Error occurred on locking entity\n"); hdl = DDS_ERRNO(rc); }