From: Chris Nandor Date: Tue, 17 Apr 2001 00:30:49 +0000 (-0400) Subject: [MacPerl-Porters] [PATCH] bsd_glob.c, gv.c fixes for Mac OS X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=6eb630b73347b42c0fa5d74c89e91392e903f094;p=p5sagit%2Fp5-mst-13.2.git [MacPerl-Porters] [PATCH] bsd_glob.c, gv.c fixes for Mac OS Message-Id: p4raw-id: //depot/perl@9720 --- diff --git a/ext/File/Glob/bsd_glob.c b/ext/File/Glob/bsd_glob.c index ef9ca30..0ea502a 100644 --- a/ext/File/Glob/bsd_glob.c +++ b/ext/File/Glob/bsd_glob.c @@ -95,16 +95,20 @@ static char sscsid[]= "$OpenBSD: glob.c,v 1.8.10.1 2001/04/10 jason Exp $"; #endif #ifndef ARG_MAX -# ifdef _SC_ARG_MAX -# define ARG_MAX (sysconf(_SC_ARG_MAX)) +# ifdef MACOS_TRADITIONAL +# define ARG_MAX 65536 /* Mac OS is actually unlimited */ # else -# ifdef _POSIX_ARG_MAX -# define ARG_MAX _POSIX_ARG_MAX +# ifdef _SC_ARG_MAX +# define ARG_MAX (sysconf(_SC_ARG_MAX)) # else -# ifdef WIN32 -# define ARG_MAX 14500 /* from VC's limits.h */ +# ifdef _POSIX_ARG_MAX +# define ARG_MAX _POSIX_ARG_MAX # else -# define ARG_MAX 4096 /* from POSIX, be conservative */ +# ifdef WIN32 +# define ARG_MAX 14500 /* from VC's limits.h */ +# else +# define ARG_MAX 4096 /* from POSIX, be conservative */ +# endif # endif # endif # endif @@ -492,7 +496,7 @@ glob0(const Char *pattern, glob_t *pglob) #ifdef MACOS_TRADITIONAL if ( (*pattern == BG_TILDE) && (pglob->gl_flags & GLOB_TILDE) ) { - return(globextend(pattern, pglob)); + return(globextend(pattern, pglob, &limit)); } #endif diff --git a/gv.c b/gv.c index 8351613..117667c 100644 --- a/gv.c +++ b/gv.c @@ -1081,7 +1081,12 @@ Perl_gv_check(pTHX_ HV *stash) * module, don't bother warning */ if (file && PERL_FILE_IS_ABSOLUTE(file) - && (instr(file, "/lib/") || instr(file, ".pm"))) +#ifdef MACOS_TRADITIONAL + && (instr(file, ":lib:") +#else + && (instr(file, "/lib/") +#endif + || instr(file, ".pm"))) { continue; }