From: Junio C Hamano <gitster@pobox.com>
To: Linus Torvalds <torvalds@linux-foundation.org>
Cc: "Shawn O. Pearce" <spearce@spearce.org>, git@vger.kernel.org
Subject: Re: [PATCH] Don't segfault if we failed to inflate a packed delta
Date: Sat, 25 Aug 2007 10:56:09 -0700 [thread overview]
Message-ID: <7v8x7z5why.fsf@gitster.siamese.dyndns.org> (raw)
In-Reply-To: <alpine.LFD.0.999.0708250815150.25853@woody.linux-foundation.org> (Linus Torvalds's message of "Sat, 25 Aug 2007 08:19:17 -0700 (PDT)")
Linus Torvalds <torvalds@linux-foundation.org> writes:
> Hmm. We should actually make "unpack_entry()" return print an error and
> return NULL for these cases, rather than die, I think.
>
> Most of the callers seem to already check for NULL (not "load_tree()" in
> fast-import.c), but for something like fsck, while "die()" is obviously
> better than a SIGSEGV, we should probably continue and try to see what
> else we find.
>
> (Although, to be honest, it might not matter. If your pack-file is corrupt
> enough for this to trigger, there's seldom anything interesting fsck will
> tell, so in practical terms this probably isn't a big deal).
But if the delta does not apply we already die(). Last night I
and Shawn actually were wondering if it makes sense to have
unpack_entry() die -- quite the opposite of being nicer to fsck.
prev parent reply other threads:[~2007-08-25 17:56 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-08-25 7:26 [PATCH] Don't segfault if we failed to inflate a packed delta Shawn O. Pearce
2007-08-25 8:30 ` [PATCH 1/2] blame: check return value from read_sha1_file() Junio C Hamano
2007-08-25 8:30 ` [PATCH 2/2] pack-objects: " Junio C Hamano
2007-08-25 15:19 ` [PATCH] Don't segfault if we failed to inflate a packed delta Linus Torvalds
2007-08-25 17:56 ` Junio C Hamano [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=7v8x7z5why.fsf@gitster.siamese.dyndns.org \
--to=gitster@pobox.com \
--cc=git@vger.kernel.org \
--cc=spearce@spearce.org \
--cc=torvalds@linux-foundation.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.