Graphviz depth-first link traversal overzealously skips some links

The link detection algorithm uses a depth-firsth traversal of links;
unfortunately, this can lead to connections being incorrectly omitted.
If a too-long pathway is encountered prior to a short one, the "seen"
check will omit it when it is encountered later.

While switching to breadth-first would resolve this more correctly,
simply tracking the depth that the link was found at is sufficient.
Merge branch '4.2/graphviz-link-depth' into 4.2-trunk