projects
/
platform
/
upstream
/
perl.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
aa7b0f0
)
User may not have a valid home directory even if
author
Jarkko Hietaniemi
<jhi@iki.fi>
Fri, 14 Dec 2001 20:26:51 +0000
(20:26 +0000)
committer
Jarkko Hietaniemi
<jhi@iki.fi>
Fri, 14 Dec 2001 20:26:51 +0000
(20:26 +0000)
getpwuid() succedds.
p4raw-id: //depot/perl@13690
ext/File/Glob/t/basic.t
patch
|
blob
|
history
diff --git
a/ext/File/Glob/t/basic.t
b/ext/File/Glob/t/basic.t
index
c6fc217
..
2eb891b
100755
(executable)
--- a/
ext/File/Glob/t/basic.t
+++ b/
ext/File/Glob/t/basic.t
@@
-49,9
+49,11
@@
if ($^O ne 'MSWin32' && $^O ne 'NetWare' && $^O ne 'VMS' && $^O ne 'os2') {
($name, $home) = (getpwuid($>))[0,7];
1;
} and do {
- @a = bsd_glob("~$name", GLOB_TILDE);
- if (defined $home && (scalar(@a) != 1 || $a[0] ne $home || GLOB_ERROR)) {
- print "not ";
+ if (defined $home && defined $name && -d $home) {
+ @a = bsd_glob("~$name", GLOB_TILDE);
+ if ((scalar(@a) != 1 || $a[0] ne $home || GLOB_ERROR)) {
+ print "not ";
+ }
}
};
}