Re: [PATCH 5/5] archive-zip: stream large blobs into zip file

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

 



Nguyễn Thái Ngọc Duy  <pclouds@xxxxxxxxx> writes:

> A large blob will be read twice. One for calculating crc32, one for
> actual writing.

Is that because you need the checksum before the payload?  That is
unfortunate.  It would be nice (read: not a rejection of this patch---it
is a good first step to do it stupid but correct way before trying to
optimize it) to avoid it when the output is seekable, especially because
we are talking about a *large* payload.

> diff --git a/t/t1050-large.sh b/t/t1050-large.sh
> index fe47554..458fdde 100755
> --- a/t/t1050-large.sh
> +++ b/t/t1050-large.sh
> @@ -138,4 +138,8 @@ test_expect_success 'tar achiving' '
>  	git archive --format=tar HEAD >/dev/null
>  '
>  
> +test_expect_success 'zip achiving' '
> +	git archive --format=zip HEAD >/dev/null
> +'

Can't we do better than "we only check if it finishes without barfing; we
cannot afford to check the correctness of the output"?  The same comment
applies to all the tests you added to this file in the past 3 months.
--
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]