git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Dmitry Potapov <dpotapov@gmail.com>
To: Nicolas Pitre <nico@fluxnic.net>
Cc: Junio C Hamano <gitster@pobox.com>, git@vger.kernel.org
Subject: Re: [PATCH] sha1_file: don't malloc the whole compressed result when writing out objects
Date: Mon, 22 Feb 2010 09:27:13 +0300	[thread overview]
Message-ID: <20100222062713.GD10191@dpotapov.dyndns.org> (raw)
In-Reply-To: <alpine.LFD.2.00.1002220034540.1946@xanadu.home>

On Mon, Feb 22, 2010 at 12:50:18AM -0500, Nicolas Pitre wrote:
> 
> And what real life case would trigger this?  Given the size of the 
> window for this to happen, what are your chances?

If some process changes just one byte (or one word) back and forth
then the possibility of this is 25%. Whether such a process can
exist, I don't know... I could not imagine that anyone would want
to change the file when we add it to the repository. In any case,
it is wrong to call it a _paranoic_ mode if there is even a small
(but practically feasable) chance of this to happen.


Dmitry

      parent reply	other threads:[~2010-02-22  6:27 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-02-21  4:27 [PATCH] sha1_file: don't malloc the whole compressed result when writing out objects Nicolas Pitre
2010-02-21 19:45 ` Junio C Hamano
2010-02-21 21:26   ` Nicolas Pitre
2010-02-21 22:22     ` Junio C Hamano
2010-02-21 22:30     ` Junio C Hamano
2010-02-22  1:35       ` Nicolas Pitre
2010-02-22  5:30         ` Junio C Hamano
2010-02-22  5:50           ` Nicolas Pitre
2010-02-22  6:17             ` Junio C Hamano
2010-02-22  6:31               ` Junio C Hamano
2010-02-22 17:36                 ` Nicolas Pitre
2010-02-22 19:55                   ` Junio C Hamano
2010-02-22  6:27             ` Dmitry Potapov [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=20100222062713.GD10191@dpotapov.dyndns.org \
    --to=dpotapov@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=nico@fluxnic.net \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).