FreeBSD Bugzilla – Attachment 9048 Details for
Bug 18704
GLOB_ERR not handled correctly by glob()
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
file.diff
file.diff (text/plain), 1.45 KB, created by
douzzer
on 2000-05-21 06:30:01 UTC
(
hide
)
Description:
file.diff
Filename:
MIME Type:
Creator:
douzzer
Created:
2000-05-21 06:30:01 UTC
Size:
1.45 KB
patch
obsolete
>*** /usr/src/lib/libc/gen/glob.c Fri Feb 20 02:54:56 1998 >--- /tmp/glob.c Sun May 21 01:19:24 2000 >*************** >*** 532,540 **** > for (anymeta = 0;;) { > if (*pattern == EOS) { /* End of pattern? */ > *pathend = EOS; >! if (g_lstat(pathbuf, &sb, pglob)) >! return(0); >! > if (((pglob->gl_flags & GLOB_MARK) && > pathend[-1] != SEP) && (S_ISDIR(sb.st_mode) > || (S_ISLNK(sb.st_mode) && >--- 532,543 ---- > for (anymeta = 0;;) { > if (*pattern == EOS) { /* End of pattern? */ > *pathend = EOS; >! if (g_lstat(pathbuf, &sb, pglob)) { >! if (pglob->gl_flags & GLOB_ERR) >! return GLOB_ABEND; >! else >! return(0); >! } > if (((pglob->gl_flags & GLOB_MARK) && > pathend[-1] != SEP) && (S_ISDIR(sb.st_mode) > || (S_ISLNK(sb.st_mode) && >*************** >*** 589,599 **** > errno = 0; > > if ((dirp = g_opendir(pathbuf, pglob)) == NULL) { >! /* TODO: don't call for ENOENT or ENOTDIR? */ > if (pglob->gl_errfunc) { > g_Ctoc(pathbuf, buf); >! if (pglob->gl_errfunc(buf, errno) || >! pglob->gl_flags & GLOB_ERR) > return (GLOB_ABEND); > } > return(0); >--- 592,602 ---- > errno = 0; > > if ((dirp = g_opendir(pathbuf, pglob)) == NULL) { >! if ((pglob->gl_flags & GLOB_ERR) && (errno != ENOENT) && (errno != ENOTDIR)) >! return GLOB_ABEND; > if (pglob->gl_errfunc) { > g_Ctoc(pathbuf, buf); >! if (pglob->gl_errfunc(buf, errno)) > return (GLOB_ABEND); > } > return(0);
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 18704
: 9048