Skip to content

Commit

Permalink
Refs #21817: Add suggested changes & uncrustify
Browse files Browse the repository at this point in the history
Signed-off-by: Carlosespicur <[email protected]>
  • Loading branch information
Carlosespicur committed Nov 19, 2024
1 parent 5152155 commit ac5d2cb
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 20 deletions.
16 changes: 4 additions & 12 deletions src/cpp/database/database_queue.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@ EntityId DatabaseEntityQueue::process_datareader(
if (participant_id.first != info.domain_id)
{
throw BadParameter("Participant " + to_string(participant_guid)
+ " found in the database but it is not in the current domain");
+ " found in the database but it is not in the current domain");
}
}
catch (const Exception&)
Expand Down Expand Up @@ -265,7 +265,7 @@ EntityId DatabaseEntityQueue::process_datawriter(
if (participant_id.first != info.domain_id)
{
throw BadParameter("Participant " + to_string(participant_guid)
+ " found in the database but it is not in the current domain");
+ " found in the database but it is not in the current domain");
}
}
catch (const Exception&)
Expand Down Expand Up @@ -328,7 +328,7 @@ EntityId DatabaseEntityQueue::process_endpoint_discovery(
if (participant_id.first != info.domain_id)
{
throw BadParameter("Participant " + to_string(participant_guid)
+ " found in the database but it is not in the current domain");
+ " found in the database but it is not in the current domain");
}
}
catch (const Exception&)
Expand Down Expand Up @@ -377,15 +377,7 @@ EntityId DatabaseEntityQueue::process_endpoint_discovery(
// Create the endpoint
EntityId endpoint_id;
std::stringstream name;

if (info.kind() == EntityKind::DATAREADER)
{
name << info.topic_name << "_" << info.guid.entityId;
}
else
{
name << info.topic_name << "_" << info.guid.entityId;
}
name << info.topic_name << "_" << info.guid.entityId;

// Endpoint AppId and metadata
// TODO: get app data from info (parameters), not from participant
Expand Down
13 changes: 5 additions & 8 deletions test/dds/communication/Communication.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -80,9 +80,9 @@ class Communication
eProsima_user_DllExport Communication(
const Communication& x)
{
m_index = x.m_index;
m_index = x.m_index;

m_message = x.m_message;
m_message = x.m_message;

}

Expand All @@ -105,9 +105,9 @@ class Communication
const Communication& x)
{

m_index = x.m_index;
m_index = x.m_index;

m_message = x.m_message;
m_message = x.m_message;

return *this;
}
Expand All @@ -133,7 +133,7 @@ class Communication
const Communication& x) const
{
return (m_index == x.m_index &&
m_message == x.m_message);
m_message == x.m_message);
}

/*!
Expand Down Expand Up @@ -174,7 +174,6 @@ class Communication
return m_index;
}


/*!
* @brief This function copies the value in member message
* @param _message New value to be copied in member message
Expand Down Expand Up @@ -213,8 +212,6 @@ class Communication
return m_message;
}



private:

uint32_t m_index{0};
Expand Down

0 comments on commit ac5d2cb

Please sign in to comment.