Parcourir la source

Merge pull request #10440 from rhvgoyal/skip-dot-prefix-files

devicemapper: Skip the files with prefix "." during device map construct...
Vincent Batts il y a 10 ans
Parent
commit
67a4f1db10
1 fichiers modifiés avec 5 ajouts et 0 suppressions
  1. 5 0
      daemon/graphdriver/devmapper/deviceset.go

+ 5 - 0
daemon/graphdriver/devmapper/deviceset.go

@@ -323,6 +323,11 @@ func (devices *DeviceSet) deviceFileWalkFunction(path string, finfo os.FileInfo)
 		return nil
 	}
 
+	if strings.HasPrefix(finfo.Name(), ".") {
+		log.Debugf("Skipping file %s", path)
+		return nil
+	}
+
 	if finfo.Name() == deviceSetMetaFile {
 		log.Debugf("Skipping file %s", path)
 		return nil