Explorar o código

Merge pull request #30169 from runcom/fix-quoting

image: tarexport: do not quote integers in format string
Sebastiaan van Stijn %!s(int64=8) %!d(string=hai) anos
pai
achega
957a77f2e2
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      image/tarexport/load.go

+ 1 - 1
image/tarexport/load.go

@@ -85,7 +85,7 @@ func (l *tarexporter) Load(inTar io.ReadCloser, outStream io.Writer, quiet bool)
 		rootFS.DiffIDs = nil
 
 		if expected, actual := len(m.Layers), len(img.RootFS.DiffIDs); expected != actual {
-			return fmt.Errorf("invalid manifest, layers length mismatch: expected %q, got %q", expected, actual)
+			return fmt.Errorf("invalid manifest, layers length mismatch: expected %d, got %d", expected, actual)
 		}
 
 		for i, diffID := range img.RootFS.DiffIDs {