From 87d749f78144755b5f5fb74d51df50e1c0f273ec Mon Sep 17 00:00:00 2001 From: Brad Fitzpatrick Date: Sun, 3 Apr 2011 19:58:41 -0700 Subject: [PATCH] use fmt.Errorf instead of os.NewError(fmt.Sprintf(..)) --- lib/go/camli/client/upload.go | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/lib/go/camli/client/upload.go b/lib/go/camli/client/upload.go index 28ade1d7e..bb76e31ee 100644 --- a/lib/go/camli/client/upload.go +++ b/lib/go/camli/client/upload.go @@ -82,8 +82,7 @@ func (c *Client) jsonFromResponse(resp *http.Response) (map[string]interface{}, func (c *Client) Upload(h *UploadHandle) (*PutResult, os.Error) { error := func(msg string, e os.Error) (*PutResult, os.Error) { - err := os.NewError(fmt.Sprintf("Error uploading blob %s: %s; err=%s", - h.BlobRef, msg, e)) + err := fmt.Errorf("Error uploading blob %s: %s; err=%v", h.BlobRef, msg, e) c.log.Print(err.String()) return nil, err }