Re: [PATCH 05/12] index-pack: parse v4 header and dictionaries

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

 



On Sat, 7 Sep 2013, Nguyễn Thái Ngọc Duy wrote:

> 
> Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@xxxxxxxxx>
> ---

[...]

> @@ -1677,6 +1727,15 @@ int cmd_index_pack(int argc, const char **argv, const char *prefix)
>  	free(objects);
>  	free(index_name_buf);
>  	free(keep_name_buf);
> +	free(sha1_table);
> +	if (name_dict) {
> +		free((void*)name_dict->data);
> +		free(name_dict);
> +	}
> +	if (path_dict) {
> +		free((void*)path_dict->data);
> +		free(path_dict);
> +	}

The freeing of dictionary tables should probably have its own function 
in packv4-parse.c.  and a call to it added in free_pack_by_name() as 
well.


Nicolas

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