consume z.current prepared by Reader.Read in Reader.WriteTo
(cherry picked from commit 44f11f0954e3b3f559c75434dc811f5d57b3f742)
This commit is contained in:
parent
4ee9587f80
commit
b6a1e91d87
@ -1 +1 @@
|
||||
0.9.6-23
|
||||
0.9.6-24
|
||||
|
||||
@ -1 +1 @@
|
||||
58d90d176bffe3c836fed71cabcdbf707590266a
|
||||
a51590634bf5ef5eabadfcc2a88dc6b04dc319d7
|
||||
|
||||
@ -2,7 +2,7 @@
|
||||
|
||||
Name: isula-build
|
||||
Version: 0.9.6
|
||||
Release: 23
|
||||
Release: 24
|
||||
Summary: A tool to build container images
|
||||
License: Mulan PSL V2
|
||||
URL: https://gitee.com/openeuler/isula-build
|
||||
@ -105,6 +105,12 @@ fi
|
||||
/usr/share/bash-completion/completions/isula-build
|
||||
|
||||
%changelog
|
||||
* Wed Dec 18 2024 daisicheng <daisicheng@huawei.com> - 0.9.6-24
|
||||
- Type:bugfix
|
||||
- CVE:NA
|
||||
- SUG:NA
|
||||
- DESC:Consume z.current prepared by Reader.Read in Reader.WriteTo
|
||||
|
||||
* Sun Apr 07 2024 daisicheng <daisicheng@huawei.com> - 0.9.6-23
|
||||
- Type:bugfix
|
||||
- CVE:NA
|
||||
|
||||
@ -0,0 +1,36 @@
|
||||
From 17e8dac29df8ce00febbd08ee5d8ee922024a003 Mon Sep 17 00:00:00 2001
|
||||
From:Miloslav Trmač <mitr@redhat.com>
|
||||
Date: Fri, 30 Sep 2022 12:46:21 +0200
|
||||
Subject: [PATCH] Consume z.current prepared by Reader.Read in Reader.WriteTo
|
||||
|
||||
---
|
||||
vendor/github.com/klauspost/pgzip/gunzip.go | 13 +++++++++++++
|
||||
1 file changed, 13 insertions(+)
|
||||
|
||||
diff --git a/vendor/github.com/klauspost/pgzip/gunzip.go b/vendor/github.com/klauspost/pgzip/gunzip.go
|
||||
index d1ae730..3c4b32f 100644
|
||||
--- a/vendor/github.com/klauspost/pgzip/gunzip.go
|
||||
+++ b/vendor/github.com/klauspost/pgzip/gunzip.go
|
||||
@@ -513,6 +513,19 @@ func (z *Reader) Read(p []byte) (n int, err error) {
|
||||
|
||||
func (z *Reader) WriteTo(w io.Writer) (n int64, err error) {
|
||||
total := int64(0)
|
||||
+ avail := z.current[z.roff:]
|
||||
+ if len(avail) != 0 {
|
||||
+ n, err := w.Write(avail)
|
||||
+ if n != len(avail) {
|
||||
+ return total, io.ErrShortWrite
|
||||
+ }
|
||||
+ total += int64(n)
|
||||
+ if err != nil {
|
||||
+ return total, err
|
||||
+ }
|
||||
+ z.blockPool <- z.current
|
||||
+ z.current = nil
|
||||
+ }
|
||||
for {
|
||||
if z.err != nil {
|
||||
return total, z.err
|
||||
--
|
||||
2.33.0
|
||||
|
||||
@ -46,3 +46,4 @@ patch/0134-add-dt-for-interface-manifest-health-status-in-daemo.patch
|
||||
patch/0135-fix-the-login_test-in-daemon-for-euleros-and-openeul.patch
|
||||
patch/0136-add-manifest.json-verification-before-loading-a-tar.patch
|
||||
patch/0137-fix-cflags-for-clang-build.patch
|
||||
patch/0138-Consume-z.current-prepared-by-Reader.Read-in-Reader.patch
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user