Revision 532b74b2104bd00cbaa99e726e6a7b8997f48744 authored by Junio C Hamano on 13 March 2009, 04:46:50 UTC, committed by Junio C Hamano on 13 March 2009, 04:46:50 UTC
* js/maint-1.6.1-filter-branch-submodule:
  filter-branch: do not consider diverging submodules a 'dirty worktree'
2 parent s c26901a + 26be15f
Raw File
hstrerror.c
#include <string.h>
#include <stdio.h>
#include <netdb.h>

const char *githstrerror(int err)
{
	static char buffer[48];
	switch (err)
	{
	case HOST_NOT_FOUND:
		return "Authoritative answer: host not found";
	case NO_DATA:
		return "Valid name, no data record of requested type";
	case NO_RECOVERY:
		return "Non recoverable errors, FORMERR, REFUSED, NOTIMP";
	case TRY_AGAIN:
		return "Non-authoritative \"host not found\", or SERVERFAIL";
	}
	sprintf(buffer, "Name resolution error %d", err);
	return buffer;
}
back to top