Browse Source

x/crypto/openpgp/s2k: fix misleading function comment

Remove mention of panic from HashIdToString doc.

Change-Id: If606dc1ebad53ef5c1b052fff36499af2b44a806
Reviewed-on: https://go-review.googlesource.com/22760
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Artyom Pervukhin 9 năm trước cách đây
mục cha
commit
019870fc9d
1 tập tin đã thay đổi với 1 bổ sung1 xóa
  1. 1 1
      openpgp/s2k/s2k.go

+ 1 - 1
openpgp/s2k/s2k.go

@@ -251,7 +251,7 @@ func HashIdToHash(id byte) (h crypto.Hash, ok bool) {
 }
 
 // HashIdToString returns the name of the hash function corresponding to the
-// given OpenPGP hash id, or panics if id is unknown.
+// given OpenPGP hash id.
 func HashIdToString(id byte) (name string, ok bool) {
 	for _, m := range hashToHashIdMapping {
 		if m.id == id {