def insert_node_after(new_node, insert_after):
    """Insert new_node into buffer after insert_after."""
    next_element = insert_after['next']
    next_element['prev'] = new_node
    new_node['next'] = insert_after['next']
    insert_after['next'] = new_node
    new_node['prev'] = insert_after
    return new_node