summaryrefslogtreecommitdiff
path: root/soltools/mkdepend/include.c
diff options
context:
space:
mode:
authorHans-Joachim Lankenau <hjs@openoffice.org>2002-06-04 11:51:57 +0000
committerHans-Joachim Lankenau <hjs@openoffice.org>2002-06-04 11:51:57 +0000
commit130eb54260add9e35b322f885d581f6d2c585f1c (patch)
tree8bab2cfcb08c37658da47d8aa1893d983f7d7369 /soltools/mkdepend/include.c
parent6419651ee819566f24ee2a656a6b1f9d1661f527 (diff)
don't match directories
Diffstat (limited to 'soltools/mkdepend/include.c')
-rw-r--r--soltools/mkdepend/include.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/soltools/mkdepend/include.c b/soltools/mkdepend/include.c
index e277382ecf12..337620c26cd3 100644
--- a/soltools/mkdepend/include.c
+++ b/soltools/mkdepend/include.c
@@ -63,7 +63,7 @@ struct inclist *inc_path(file, include, dot)
* then check the exact path provided.
*/
if (!found && (dot || *include == '/')) {
- if (stat(include, &st) == 0) {
+ if (stat(include, &st) == 0 && !( st.st_mode & S_IFDIR)) {
ip = newinclude(include, include);
found = TRUE;
}
@@ -87,7 +87,7 @@ struct inclist *inc_path(file, include, dot)
strcpy(path + (p-file) + 1, include);
}
remove_dotdot(path);
- if (stat(path, &st) == 0) {
+ if (stat(path, &st) == 0 && !( st.st_mode & S_IFDIR)) {
ip = newinclude(path, include);
found = TRUE;
}
@@ -103,7 +103,7 @@ struct inclist *inc_path(file, include, dot)
for (pp = includedirs; *pp; pp++) {
sprintf(path, "%s/%s", *pp, include);
remove_dotdot(path);
- if (stat(path, &st) == 0) {
+ if (stat(path, &st) == 0 && !(st.st_mode & S_IFDIR)) {
ip = newinclude(path, include);
found = TRUE;
break;