Windows permits login names to include spaces!

This commit is contained in:
Andrew Johnson
2004-10-22 15:11:41 +00:00
parent a4790a1dc2
commit 69fc21474b

View File

@@ -413,6 +413,7 @@ sub GetUser {
# add to this list if new possibilities arise,
# currently it's UNIX and WIN32:
$user = $ENV{USER} || $ENV{USERNAME} || Win32::LoginName();
$user =~ s/\s+//g; # Bl**dy Windows stupidity...
unless ($user) {
print "Strange, I cannot figure out your user name!\n";