author | Shawn O. Pearce <spearce@spearce.org> | |
Thu, 1 Feb 2007 20:52:33 +0000 (15:52 -0500) | ||
committer | Junio C Hamano <junkio@cox.net> | |
Fri, 2 Feb 2007 06:24:17 +0000 (22:24 -0800) | ||
commit | 072db2789c21314cfbf43215186341d0b2b47523 | |
tree | 2326e8e1049e6605c8027520b350beb52cdf7414 | tree | snapshot |
parent | 54a15a8df269315adf7110a87391bd5bef7e90f0 | commit | diff |
Refactor open_packed_git to return an error code.
Because I want to reuse open_packed_git in a context where I don't
want the process to die if the packfile in question is bogus, I'm
changing its behavior to return error("...") rather than die("...")
when it detects something is wrong with the packfile it was given.
Right now we still must die out of use_pack should open_packed_git
fail, as none of use_pack's callers are prepared to handle a failure
from that function.
Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
Because I want to reuse open_packed_git in a context where I don't
want the process to die if the packfile in question is bogus, I'm
changing its behavior to return error("...") rather than die("...")
when it detects something is wrong with the packfile it was given.
Right now we still must die out of use_pack should open_packed_git
fail, as none of use_pack's callers are prepared to handle a failure
from that function.
Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
sha1_file.c | diff | blob | history |