Handles an issue in windows with large code bases not squash merging correctly.

Summary: Handles an issue in windows with large code bases not squash merging correctly, this only catches the issue it doesn't really do any recovery.

Test Plan: We have been running this change in our work environment, it's a hard bug to replicate but when it has reared it's head this has caught it.

Reviewers: waynea, #blessed_reviewers, epriestley

Reviewed By: #blessed_reviewers, epriestley

Subscribers: epriestley, Korvin, hach-que

Maniphest Tasks: T4884

Differential Revision: https://secure.phabricator.com/D8729