Skip to content

Commit

Permalink
print bytes
Browse files Browse the repository at this point in the history
  • Loading branch information
schollz committed Jul 25, 2024
1 parent 4f1a6a8 commit 8f226f7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/utils/utils.go
Original file line number Diff line number Diff line change
Expand Up @@ -575,11 +575,11 @@ func ValidFileName(fname string) (err error) {
// make sure it doesn't contain unicode or invisible characters
for _, r := range fname {
if !unicode.IsGraphic(r) {
err = fmt.Errorf("non-graphical unicode: %x U+%d in '%s'", string(r), r, fname)
err = fmt.Errorf("non-graphical unicode: %x U+%d in '%x'", string(r), r, fname)
return
}
if !unicode.IsPrint(r) {
err = fmt.Errorf("non-printable unicode: %x U+%d in '%s'", string(r), r, fname)
err = fmt.Errorf("non-printable unicode: %x U+%d in '%x'", string(r), r, fname)
return
}
}
Expand Down

0 comments on commit 8f226f7

Please sign in to comment.