Skip to content

Commit

Permalink
Modified create_linked_list functions to not null terminal link pointers
Browse files Browse the repository at this point in the history
  • Loading branch information
John Wellbelove committed Mar 1, 2025
1 parent 260a3f4 commit acc0b4b
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions include/etl/intrusive_links.h
Original file line number Diff line number Diff line change
Expand Up @@ -945,8 +945,7 @@ namespace etl
{
TLink* current = &first;
((current->etl_next = &links, static_cast<TLink&>(links).etl_previous = current, current = &links), ...);
current->etl_next = ETL_NULLPTR;


return current;
}

Expand All @@ -959,12 +958,10 @@ namespace etl
{
TLink* current = first;
((current->etl_next = links, static_cast<TLink*>(links)->etl_previous = current, current = links), ...);
current->etl_next = ETL_NULLPTR;

return current;
}
#elif ETL_USING_CPP11

//***************************************************************************
/// Create a linked list from a number of bidirectional_link nodes.
//***************************************************************************
Expand Down

0 comments on commit acc0b4b

Please sign in to comment.