Skip to content

Commit 3706cd8

Browse files
vivekv96ianlancetaylor
authored andcommitted
debug/dwarf: call strings.EqualFold instead of calling Lower twice
Change-Id: I8dcb425c37a067277549ba3bda6a21206459890a GitHub-Last-Rev: dc51b9b GitHub-Pull-Request: golang#35132 Reviewed-on: https://go-review.googlesource.com/c/go/+/203097 Run-TryBot: Ian Lance Taylor <iant@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Ian Lance Taylor <iant@golang.org>
1 parent 06bdd52 commit 3706cd8

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/debug/dwarf/line.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -806,7 +806,7 @@ func pathJoin(dirname, filename string) string {
806806
// DOS-style path.
807807
drive2, filename := splitDrive(filename)
808808
if drive2 != "" {
809-
if strings.ToLower(drive) != strings.ToLower(drive2) {
809+
if !strings.EqualFold(drive, drive2) {
810810
// Different drives. There's not much we can
811811
// do here, so just ignore the directory.
812812
return drive2 + filename

0 commit comments

Comments
 (0)