Blame SOURCES/ltrace-0.7.91-XDG_CONFIG_DIRS-2.patch

e7106e
From 8fbbcfc92a7ad388334bf162222ddee1a03c9d29 Mon Sep 17 00:00:00 2001
e7106e
From: Petr Machata <pmachata@redhat.com>
e7106e
Date: Mon, 2 Mar 2015 17:21:36 +0100
e7106e
Subject: [PATCH] Also muffle warnings about weird file types referenced by
e7106e
 environment
e7106e
e7106e
---
e7106e
 options.c | 5 +++--
e7106e
 1 file changed, 3 insertions(+), 2 deletions(-)
e7106e
e7106e
diff --git a/options.c b/options.c
e7106e
index 61d1633..e602848 100644
e7106e
--- a/options.c
e7106e
+++ b/options.c
e7106e
@@ -505,8 +505,9 @@ opt_F_get_kind(struct opt_F_t *entry)
e7106e
 		} else if (S_ISREG(st.st_mode) || S_ISLNK(st.st_mode)) {
e7106e
 			entry->kind = OPT_F_FILE;
e7106e
 		} else {
e7106e
-			fprintf(stderr, "%s is neither a regular file, "
e7106e
-				"nor a directory.\n", entry->pathname);
e7106e
+			if (entry->origin == OPT_F_CMDLINE)
e7106e
+				fprintf(stderr, "%s is neither a regular file, "
e7106e
+					"nor a directory.\n", entry->pathname);
e7106e
 			entry->kind = OPT_F_BROKEN;
e7106e
 		}
e7106e
 	}
e7106e
-- 
e7106e
2.1.0
e7106e