Fix/simplify some if statement comparisons

This commit is contained in:
Tim Wojtulewicz 2023-01-14 16:30:53 -07:00
parent 103b381874
commit 5bfd84a903
7 changed files with 13 additions and 12 deletions

View file

@ -276,11 +276,12 @@ AnonymizeIPAddr_A50::Node* AnonymizeIPAddr_A50::make_peer(ipaddr32_t a, Node* n)
// the parent of the two new ones.
Node* down[2];
if ( ! (down[0] = new_node()) )
down[0] = new_node();
if ( ! down[0] )
return nullptr;
if ( ! (down[1] = new_node()) )
down[1] = new_node();
if ( ! down[1] )
{
free_node(down[0]);
return nullptr;