Skip to content
This repository was archived by the owner on Feb 8, 2021. It is now read-only.

Commit d2448a0

Browse files
committed
Merge pull request #19524 from LK4D4/iocopy_writeto
Use bufio.Reader in io.Copy source for overlay.copyRegular
2 parents 16faf8f + 3f5e1c6 commit d2448a0

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

daemon/graphdriver/overlay/copy.go

+2-2
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,12 @@ package overlay
44

55
import (
66
"fmt"
7-
"io"
87
"os"
98
"path/filepath"
109
"syscall"
1110
"time"
1211

12+
"github.com/docker/docker/pkg/pools"
1313
"github.com/docker/docker/pkg/system"
1414
)
1515

@@ -32,7 +32,7 @@ func copyRegular(srcPath, dstPath string, mode os.FileMode) error {
3232
}
3333
defer dstFile.Close()
3434

35-
_, err = io.Copy(dstFile, srcFile)
35+
_, err = pools.Copy(dstFile, srcFile)
3636

3737
return err
3838
}

0 commit comments

Comments
 (0)