On Wed, Nov 24, 2010 at 1:07 AM, Junio C Hamano <gitster@xxxxxxxxx> wrote: > Erik Faye-Lund <kusmabite@xxxxxxxxx> writes: > >> Currently do_lstat always sets errno to 0 on success. This incorrectly >> overwrites previous errors. >> >> Fetch the error-code into a temporary variable instead, and assign that >> to errno on failure. >> >> Signed-off-by: Erik Faye-Lund <kusmabite@xxxxxxxxx> >> --- >> >> A bug I found while hunting down another regression. maint-worthy, perhaps? > > I would say so, as long as the error return from get_file_attr() is > trustworthy. It looks trustworthy to me; it returns 0 if GetFileAttributesExA succeeds, and either EACCES, ENAMETOOLONG, ENOMEM or ENOENT based on the result of GetLastError(). -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html