code: func (c *chainView) findFork(node *blockNode) *blockNode {
  	// No fork point for node that doesn't exist.
  	if node == nil {
  		return nil
  	}
  
  	// When the height of the passed node is higher than the height of the
  	// tip of the current chain view, walk backwards through the nodes of
  	// the other chain until the heights match (or there or no more nodes in
  	// which case there is no common node between the two).
  	//
  	// NOTE: This isn't strictly necessary as the following section will
  	// find the node as well, however, it is more efficient to avoid the
  	// contains check since it is already known that the common node can't
  	// possibly be past the end of the current chain view.  It also allows
  	// this code to take advantage of any potential future optimizations to
  	// the Ancestor function such as using an O(log n) skip list.
  	chainHeight := c.height()
  	if node.height > chainHeight {
  		node = node.Ancestor(chainHeight)
  	}
  
  	// Walk the other chain backwards as long as the current one does not
  	// contain the node or there are no more nodes in which case there is no
  	// common node between the two.
  	for node != nil && !c.contains(node) {
  		node = node.parent
  	}
  
  	return node
  }
docs: // findFork returns the final common block between the provided node and the
  // the chain view.  It will return nil if there is no common block.  This only
  // differs from the exported version in that it is up to the caller to ensure
  // the lock is held.
  //
  // See the exported FindFork comments for more details.
  //
  // This function MUST be called with the view mutex locked (for reads).