summaryrefslogtreecommitdiff
path: root/gcc/incpath.c
diff options
context:
space:
mode:
authormrs <mrs@138bc75d-0d04-0410-961f-82ee72b054a4>2016-11-07 18:33:49 +0000
committermrs <mrs@138bc75d-0d04-0410-961f-82ee72b054a4>2016-11-07 18:33:49 +0000
commitbf220b0a909afd9ca5400732d6c4927c4fefaa7f (patch)
tree17c8bd4050275278048f9cc7571adb35fc9b3dd6 /gcc/incpath.c
parentec174c00af06f090ddd102572ad9f507962bd890 (diff)
downloadgcc-bf220b0a909afd9ca5400732d6c4927c4fefaa7f.tar.gz
2016-11-06 Jack Howarth <howarth.at.gcc@gmail.com>
PR driver/78206 * incpath.c: (remove_dup(): Also silently ignore EPERM. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@241919 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/incpath.c')
-rw-r--r--gcc/incpath.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/gcc/incpath.c b/gcc/incpath.c
index ea40f4a9323..952d5c4727d 100644
--- a/gcc/incpath.c
+++ b/gcc/incpath.c
@@ -253,8 +253,9 @@ remove_duplicates (cpp_reader *pfile, struct cpp_dir *head,
if (stat (cur->name, &st))
{
- /* Dirs that don't exist are silently ignored, unless verbose. */
- if (errno != ENOENT)
+ /* Dirs that don't exist or have denied permissions are
+ silently ignored, unless verbose. */
+ if ((errno != ENOENT) && (errno != EPERM))
cpp_errno (pfile, CPP_DL_ERROR, cur->name);
else
{