missing includes, intializers, consts
[apps/madmutt.git] / muttlib.c
index 24f4ef3..9c835d1 100644 (file)
--- a/muttlib.c
+++ b/muttlib.c
@@ -1158,15 +1158,9 @@ FILE *mutt_open_read (const char *path, pid_t * thepid)
         *thepid = mutt_create_filter (s, NULL, &f, NULL);
         mem_free (&s);
     } else {
-        struct stat st;
-
-        if (stat (path, &st) < 0)
-            return (NULL);
-        if (S_ISDIR (st.st_mode)) {
-            errno = EINVAL;
-            return (NULL);
-        }
         f = fopen (path, "r");
+        if (!f)
+            return NULL;
         *thepid = -1;
     }