@@ -57,16 +57,16 @@ func (daemon *Daemon) ContainerArchivePath(name string, path string) (content io
5757// ContainerExtractToDir extracts the given archive to the specified location
5858// in the filesystem of the container identified by the given name. The given
5959// path must be of a directory in the container. If it is not, the error will
60- // be an errdefs.InvalidParameter. If noOverwriteDirNonDir is true then it will
61- // be an error if unpacking the given content would cause an existing directory
62- // to be replaced with a non-directory and vice versa .
63- func (daemon * Daemon ) ContainerExtractToDir (name , path string , copyUIDGID , noOverwriteDirNonDir bool , content io.Reader ) error {
60+ // be an errdefs.InvalidParameter. It returns an error if unpacking the given
61+ // content would cause an existing directory to be replaced with a non- directory
62+ // or vice versa, unless allowOverwriteDirWithFile is set to true .
63+ func (daemon * Daemon ) ContainerExtractToDir (name , path string , copyUIDGID , allowOverwriteDirWithFile bool , content io.Reader ) error {
6464 ctr , err := daemon .GetContainer (name )
6565 if err != nil {
6666 return err
6767 }
6868
69- err = daemon .containerExtractToDir (ctr , path , copyUIDGID , noOverwriteDirNonDir , content )
69+ err = daemon .containerExtractToDir (ctr , path , copyUIDGID , allowOverwriteDirWithFile , content )
7070 if err != nil {
7171 if os .IsNotExist (err ) {
7272 return containerFileNotFound {path , name }
0 commit comments