Create more robust parent-process walking code.

This fixes a NullReferenceException that occurs when the current process has no (accessible) parent process.

Also, it's shorter, and the implementation is reused in the Tfs and VisualStudio reporters.

--HG--
extra : amend_source : ca29ccd9dbffd4dac0e5820e2a0362fbca6c0209