Re: revision.c alters commit object state ; also no cleanup

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

 



On Mon, Aug 26, 2019 at 11:14:13AM -0700, Junio C Hamano wrote:
> Mike Hommey <mh@xxxxxxxxxxxx> writes:
> 
> > First, revision.c doesn't come with a function to clear a struct
> > rev_info....
> > Then, revision.c kind of does nasty things to commit objects...
> 
> Yeah, these two stem from the "run once and let exit() clean things
> up" design the oldest part of the system shares.  Regarding the
> latter, i.e. parent rewriting, I recall that there is a codepath
> that saves the original true parents away in a second field when we
> know we would want to show it (and avoid the overhead of copying
> when we do not have to), so you should be able to extend it to keep
> the original parent list.

I guess you're refering to save_parents/get_saved_parents? Would it make
sense for things to be reversed, as in, make revision.c keep the
simplified parents separately, and traverse through that?

Mike



[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