printf: replace %#v with the more explicit %q

Signed-off-by: Nicola Murino <nicola.murino@gmail.com>
This commit is contained in:
Nicola Murino
2023-02-27 19:02:43 +01:00
parent a23fdea9e3
commit dba088daed
80 changed files with 580 additions and 580 deletions

View File

@@ -147,7 +147,7 @@ Please take a look at the usage below to customize the serving parameters`,
_, err := common.NewCertManager(keyPairs, filepath.Clean(defaultConfigDir),
"FTP portable")
if err != nil {
fmt.Printf("Unable to load FTPS key pair, cert file %#v key file %#v error: %v\n",
fmt.Printf("Unable to load FTPS key pair, cert file %q key file %q error: %v\n",
portableFTPSCert, portableFTPSKey, err)
os.Exit(1)
}
@@ -163,7 +163,7 @@ Please take a look at the usage below to customize the serving parameters`,
_, err := common.NewCertManager(keyPairs, filepath.Clean(defaultConfigDir),
"WebDAV portable")
if err != nil {
fmt.Printf("Unable to load WebDAV key pair, cert file %#v key file %#v error: %v\n",
fmt.Printf("Unable to load WebDAV key pair, cert file %q key file %q error: %v\n",
portableWebDAVCert, portableWebDAVKey, err)
os.Exit(1)
}
@@ -480,7 +480,7 @@ func getFileContents(name string) (string, error) {
return "", err
}
if fi.Size() > 1048576 {
return "", fmt.Errorf("%#v is too big %v/1048576 bytes", name, fi.Size())
return "", fmt.Errorf("%q is too big %v/1048576 bytes", name, fi.Size())
}
contents, err := os.ReadFile(name)
if err != nil {