libgit2/libgit2 — pull request #1041 by pwkelley (2012-11-02 15:32:54+00:00)
Title: Prefer GetLastError() for GITERR_OS on Win32

Previously errno was preferred, and errno was often found to be set to something less important than what is in GetLastError(). This reverses the priority on Win32 -- we prefer GetLastError(), unless it's zero, in which case we use errno.