Re: [PATCH 1/2] unpack-trees: handle lstat failure for existing directory
- From
Miles Bader <miles@gnu.org>
- Date
- Jan 13, 2011, 04:37 UTC
- Message-ID
- <buobp3ls9l1.fsf@dhlpc061.dev.necel.com>
- In-Reply-To
- <20110113022636.GB8635@burratino>
Jonathan Nieder <jrnieder@gmail.com> writes:
Show 9 quoted lines
> @@ -1382,7 +1382,9 @@ static int verify_absent_1(struct cache_entry *ce,
> return check_ok_to_remove(ce->name, ce_namelen(ce),
> ce_to_dtype(ce), ce, &st,
> error_type, o);
> -
> + if (errno != ENOENT)
> + return error("cannot stat '%s': %s", ce->name,
> + strerror(errno));
> return 0;Is errno guaranteed to be set to something relevant at this point in the code...?
-miels
-- Religion, n. A daughter of Hope and Fear, explaining to Ignorance the nature of the Unknowable.