daemon: Mount(): use container's driver information for error-message
Use the information stored as part of the container for the error-message, instead of querying the current storage driver from the daemon. Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
This commit is contained in:
parent
239d9c5eda
commit
9d74c7ab99
3 changed files with 2 additions and 4 deletions
|
@ -81,7 +81,6 @@ func (i *ImageService) Cleanup() error {
|
|||
// GraphDriverName returns the name of the graph drvier
|
||||
// moved from Daemon.GraphDriverName, used by:
|
||||
// - newContainer
|
||||
// - to report an error in Daemon.Mount(container)
|
||||
func (i *ImageService) GraphDriverName() string {
|
||||
return ""
|
||||
}
|
||||
|
|
|
@ -1273,8 +1273,8 @@ func (daemon *Daemon) Mount(container *container.Container) error {
|
|||
// on non-Windows operating systems.
|
||||
if runtime.GOOS != "windows" {
|
||||
daemon.Unmount(container)
|
||||
return fmt.Errorf("Error: driver %s is returning inconsistent paths for container %s ('%s' then '%s')",
|
||||
daemon.imageService.GraphDriverName(), container.ID, container.BaseFS, dir)
|
||||
return fmt.Errorf("driver %s is returning inconsistent paths for container %s ('%s' then '%s')",
|
||||
container.Driver, container.ID, container.BaseFS, dir)
|
||||
}
|
||||
}
|
||||
container.BaseFS = dir // TODO: combine these fields
|
||||
|
|
|
@ -175,7 +175,6 @@ func (i *ImageService) Cleanup() error {
|
|||
// GraphDriverName returns the name of the graph drvier
|
||||
// moved from Daemon.GraphDriverName, used by:
|
||||
// - newContainer
|
||||
// - to report an error in Daemon.Mount(container)
|
||||
func (i *ImageService) GraphDriverName() string {
|
||||
return i.layerStore.DriverName()
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue