Skip to content

Commit ceea57b

Browse files
committed
cli/command/container: copyDockerConfigIntoContainer: close TarWriter
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
1 parent effdf1b commit ceea57b

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

cli/command/container/create.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -428,6 +428,7 @@ func copyDockerConfigIntoContainer(ctx context.Context, apiClient client.APIClie
428428
})
429429

430430
if _, err := io.Copy(tarWriter, &configBuf); err != nil {
431+
_ = tarWriter.Close()
431432
return fmt.Errorf("writing config to tar file for config copy: %w", err)
432433
}
433434

0 commit comments

Comments
 (0)