Browse Source

Add requested comments about old buggy behavior

Address comment: https://github.com/docker/docker/pull/25825/files/246d1eb58e807f2cf2d2b387e267dcfa228f96a8#r75242138

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
Brian Goff 9 năm trước cách đây
mục cha
commit
c7075bd149
1 tập tin đã thay đổi với 2 bổ sung0 xóa
  1. 2 0
      volume/local/local.go

+ 2 - 0
volume/local/local.go

@@ -95,6 +95,8 @@ func New(scope string, rootUID, rootGID int) (*Root, error) {
 			if err := json.Unmarshal(b, &opts); err != nil {
 				return nil, err
 			}
+			// Make sure this isn't an empty optsConfig.
+			// This could be empty due to buggy behavior in older versions of Docker.
 			if !reflect.DeepEqual(opts, optsConfig{}) {
 				v.opts = &opts
 			}