Skip to content

Commit

Permalink
Fix panic if a tempfile cannot be created
Browse files Browse the repository at this point in the history
  • Loading branch information
jcmoraisjr committed Feb 3, 2017
1 parent b90003a commit b7e8bde
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion core/pkg/net/ssl/ssl.go
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ func AddOrUpdateCertAndKey(name string, cert, key, ca []byte) (*ingress.SSLCert,

tempPemFile, err := ioutil.TempFile(ingress.DefaultSSLDirectory, pemName)
if err != nil {
return nil, fmt.Errorf("could not create temp pem file %v: %v", tempPemFile.Name(), err)
return nil, fmt.Errorf("could not create temp pem file %v: %v", pemFileName, err)
}

_, err = tempPemFile.Write(cert)
Expand Down

0 comments on commit b7e8bde

Please sign in to comment.