Re: [PATCH v5 2/2] attr: add flag `--source` to work with tree-ish

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Jan 12, 2023 at 2:21 PM Ævar Arnfjörð Bjarmason
<avarab@xxxxxxxxx> wrote:
>
>
> 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.

Let me add this to v7! Thanks




[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux