* Insert the given node 'node' into the subtree starting
* at 'pos' (while keeping the tree somewhat balanced).
*
+ * @param heap heap to modify
* @param pos existing tree
* @param node node to insert (which may be a subtree itself)
*/
else if (root->right_child == NULL)
{
heap->root = root->left_child;
- if (root->left_child != NULL)
- root->left_child->parent = NULL;
+ root->left_child->parent = NULL;
}
else
{