Re: [PATCH 2/2] gc: Remove garbage .idx files from pack dir

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

 



Doug Kelly <dougk.ff7@xxxxxxxxx> writes:

> +static struct string_list pack_garbage = STRING_LIST_INIT_DUP;
> +
>  static char *pidfile;
>  
> +static void clean_pack_garbage(void)
> +{
> +	int i;
> +	for (i = 0; i < pack_garbage.nr; i++)
> +		unlink_or_warn(pack_garbage.items[i].string);
> +	string_list_clear(&pack_garbage, 0);
> +}
> +
>  static void remove_pidfile(void)
>  {
>  	if (pidfile)
> @@ -57,6 +67,12 @@ static void remove_pidfile_on_signal(int signo)
>  	raise(signo);
>  }
>  
> +static void report_pack_garbage(unsigned seen_bits, const char *path)

This change makes"pidfile management" and "pack garbage cleaning"
tangled in the result.  By inserting the definition of the variable
pack_garbage and the function clean_pack_garbage() just before this
new function, you can keep everything related to 'pack garbage
cleaning" together.

--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[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]