Re: [PATCH v2 03/19] gendwarfksyms: Add address matching

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

 



On Thu, Aug 29, 2024 at 03:22:25AM +0900, Masahiro Yamada wrote:
> On Fri, Aug 16, 2024 at 2:39 AM Sami Tolvanen <samitolvanen@xxxxxxxxxx> wrote:
> >  int symbol_read_exports(FILE *file)
> > @@ -57,13 +93,14 @@ int symbol_read_exports(FILE *file)
> >                 if (is_exported(name))
> >                         continue; /* Ignore duplicates */
> >
> > -               sym = malloc(sizeof(struct symbol));
> > +               sym = calloc(1, sizeof(struct symbol));
> 
> 
> 
> I am tired of noise changes when reviewing this patch set.
> 
> 
> 2/19 added malloc(), which is immediately replaced with calloc() by 3/19.

This was changed to calloc because the structure now has a new field
that should be zero-initialized, but I do agree, this could have
just been a calloc from the beginning. I'll change this in the next
version.

I did try to make sure there wouldn't be too much churn in the series,
but clearly I've missed a few places. Hopefully there's nothing
equally egregious in the later patches!

Sami




[Index of Archives]     [Linux&nblp;USB Development]     [Linux Media]     [Video for Linux]     [Linux Audio Users]     [Yosemite Secrets]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux