Skip to content

Commit 248e192

Browse files
committed
os: isWine: be compatible with older versions of wine, too
Turns out wine 5.x doesn't export WINEUSERNAME.
1 parent 4f5940e commit 248e192

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/os/path_windows_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ func TestFixLongPath(t *testing.T) {
5454
// isWine returns true if executing on wine (Wine Is Not an Emulator), which
5555
// is compatible with windows but does not reproduce all its quirks.
5656
func isWine() bool {
57-
return os.Getenv("WINEUSERNAME") != ""
57+
return os.Getenv("WINECONFIGDIR") != ""
5858
}
5959

6060
func TestMkdirAllExtendedLength(t *testing.T) {

0 commit comments

Comments
 (0)