From: "Ævar Arnfjörð Bjarmason" <avarab@gmail.com>
To: Karthik Nayak <karthik.188@gmail.com>
Cc: git@vger.kernel.org, Toon Claes <toon@iotcl.com>
Subject: Re: [PATCH v5 2/2] attr: add flag `--source` to work with tree-ish
Date: Thu, 12 Jan 2023 14:20:56 +0100 [thread overview]
Message-ID: <230112.86lem728ig.gmgdl@evledraar.gmail.com> (raw)
In-Reply-To: <23813496fc73b7e5cb9f09b166e05c9a02bac43c.1671793109.git.karthik.188@gmail.com>
On Mon, Jan 02 2023, Karthik Nayak wrote:
> +static struct attr_stack *read_attr_from_blob(struct index_state *istate,
> + const struct object_id *tree_oid,
> + const char *path, unsigned flags)
> +{
> + struct object_id oid;
> + unsigned long sz;
> + enum object_type type;
> + void *buf;
> + unsigned short mode;
> +
> + if (!tree_oid)
> + return NULL;
> +
> + if (get_tree_entry(istate->repo, tree_oid, path, &oid, &mode))
> + return NULL;
> +
> + buf = read_object_file(&oid, &type, &sz);
Here you flip-flop between istate->repo and "the_repository". I think
you want to use repo_read_object_file(istate->repo, ...) instead.
next prev parent reply other threads:[~2023-01-12 13:22 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <https://lore.kernel.org/git/cover.1671630304.git.karthik.188@gmail.com/>
2023-01-02 11:04 ` [PATCH v5 0/2] check-attr: add support to work with tree-ish Karthik Nayak
2023-01-02 11:04 ` [PATCH v5 1/2] t0003: move setup for `--all` into new block Karthik Nayak
2023-01-02 11:04 ` [PATCH v5 2/2] attr: add flag `--source` to work with tree-ish Karthik Nayak
2023-01-02 23:38 ` Junio C Hamano
2023-01-04 10:25 ` Karthik Nayak
2023-01-11 11:30 ` Phillip Wood
2023-01-12 10:53 ` Karthik Nayak
2023-01-12 13:20 ` Ævar Arnfjörð Bjarmason [this message]
2023-01-14 8:26 ` Karthik Nayak
2023-01-09 9:10 ` [PATCH v5 0/2] check-attr: add support " Karthik Nayak
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=230112.86lem728ig.gmgdl@evledraar.gmail.com \
--to=avarab@gmail.com \
--cc=git@vger.kernel.org \
--cc=karthik.188@gmail.com \
--cc=toon@iotcl.com \
/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.