In perl.git, the branch blead has been updated <http://perl5.git.perl.org/perl.git/commitdiff/99b234bca42d2b5f9f5f74960bfd693b6d9c0b27?hp=907196b2ca1c36611c32cb89c75e791391979005>
- Log ----------------------------------------------------------------- commit 99b234bca42d2b5f9f5f74960bfd693b6d9c0b27 Author: Jarkko Hietaniemi <[email protected]> Date: Sat Feb 13 19:34:20 2016 -0500 Skip the length sanity check if d_name is pointer or less. [perl #127511] v5.23.7-308-g1d41bb7 broke t/op/threads-dirh.t on solaris threaded builds In other words, skip it if the dirent->d_name is a pointer (char *) or less (struct-final char d_name[1], as it seems to be in Solaris). The length sanity check is meant for places where the d_name is a true array. Follow-up to 1d41bb72. ----------------------------------------------------------------------- Summary of changes: sv.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sv.c b/sv.c index c214c99..819a250 100644 --- a/sv.c +++ b/sv.c @@ -13108,7 +13108,7 @@ Perl_dirp_dup(pTHX_ DIR *const dp, CLONE_PARAMS *const param) pos = PerlDir_tell(dp); if ((dirent = PerlDir_read(dp))) { len = d_namlen(dirent); - if (len > sizeof(dirent->d_name)) { + if (len > sizeof(dirent->d_name) && sizeof(dirent->d_name) > PTRSIZE) { /* If the len is somehow magically longer than the * maximum length of the directory entry, even though * we could fit it in a buffer, we could not copy it -- Perl5 Master Repository
