author | Tom Preston-Werner <tom@github.com> | |
Sat, 1 Nov 2008 18:44:45 +0000 (11:44 -0700) | ||
committer | Junio C Hamano <gitster@pobox.com> | |
Sun, 2 Nov 2008 08:54:29 +0000 (01:54 -0700) | ||
commit | a80732897931c737c01d04289dd1512bd12a4b04 | |
tree | 35c32c33516e3fc307f5a2f6a7681a347700c672 | tree | snapshot |
parent | a240de1137bd63a969c6bd56ab5186d7216e28ca | commit | diff |
connect.c: add a way for git-daemon to pass an error back to client
The current behavior of git-daemon is to simply close the connection on
any error condition. This leaves the client without any information as
to the cause of the failed fetch/push/etc.
This patch allows get_remote_heads to accept a line prefixed with "ERR"
that it can display to the user in an informative fashion. Once clients
can understand this ERR line, git-daemon can be made to properly report
"repository not found", "permission denied", or other errors.
Example
S: ERR No matching repository.
C: fatal: remote error: No matching repository.
Signed-off-by: Tom Preston-Werner <tom@github.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
The current behavior of git-daemon is to simply close the connection on
any error condition. This leaves the client without any information as
to the cause of the failed fetch/push/etc.
This patch allows get_remote_heads to accept a line prefixed with "ERR"
that it can display to the user in an informative fashion. Once clients
can understand this ERR line, git-daemon can be made to properly report
"repository not found", "permission denied", or other errors.
Example
S: ERR No matching repository.
C: fatal: remote error: No matching repository.
Signed-off-by: Tom Preston-Werner <tom@github.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
connect.c | diff | blob | history |