Fix a crash when the right-side diff doesn't have a header.

There was an error when parsing a diff where there were headers on the
left-hand side but not the right-hand side. The solution was found by
Ze Lin Xiao at NetApp.

Fixes bug #2876
Fix unescaping comment text in the diff viewer when the text is blank.

If the comment text was blank, we'd hit a failure when unescaping the
text. I believe this may have been a change in jquery when passing in an
empty string to html().

Now we only do the unescaping logic if the comment text is blank.

Ideally, this would use _.unescape, but we don't have a new enough
underscore.js yet.
Stop showing a console window when using cleartool on Windows 7.

When running on Windows 7 and using cleartool, a consoel window would
show up for every invocation. Switching the Popen calls to pass
shell=True prevents his from happening.

Reviewed at http://reviews.reviewboard.org/r/3804/
Rework the Mercurial version checking to not break.

The Mercurial version checking was breaking in weird ways. This change
attempts to do a better job at checking the version.

First, we use their own version() function, if available.

If we can't import that, we'll try getting __version__ again, but in a
different way. We'll import the module and not the constant within it.

If that doesn't work, or if we get a version of None, we set it to an
empty string, which will result in the 'if <= 1.2' check passing.
Release Review Board 1.7.3.