From d2b212ae6bc6a1c7ae34fc87296692060cb1a997 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mika=C3=ABl=20Cluseau?= Date: Thu, 28 Feb 2019 10:15:35 +1100 Subject: [PATCH] boot-img: better error --- cmd/dkl-local-server/boot-img.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/cmd/dkl-local-server/boot-img.go b/cmd/dkl-local-server/boot-img.go index 45c58ff..a8a631f 100644 --- a/cmd/dkl-local-server/boot-img.go +++ b/cmd/dkl-local-server/boot-img.go @@ -3,6 +3,7 @@ package main import ( "archive/tar" "compress/gzip" + "fmt" "io" "io/ioutil" "log" @@ -107,7 +108,7 @@ func setupBootImage(bootImg *os.File, ctx *renderContext) (err error) { err = syscall.Mount(dev+"p1", tempDir, "vfat", 0, "") if err != nil { - return + return fmt.Errorf("failed to mount %s to %s: %v", dev+"p1", tempDir, err) } defer func() {