[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [bug-mailutils] input in flex scanner failed
From: |
Sergey Poznyakoff |
Subject: |
Re: [bug-mailutils] input in flex scanner failed |
Date: |
Sun, 18 Apr 2010 21:12:45 +0300 |
Hola Jordi!
> if a directory ~/.mail exists, /bin/mail will fail to work.
Thanks. I have applied the following patch:
diff --git a/mailbox/cfg_lexer.l b/mailbox/cfg_lexer.l
index f530ca2..998d84d 100644
--- a/mailbox/cfg_lexer.l
+++ b/mailbox/cfg_lexer.l
@@ -333,6 +333,14 @@ mu_cfg_parse_file (mu_cfg_tree_t **return_tree, const char
*file, int flags)
free (full_name);
return ENOENT;
}
+ else if (!S_ISREG (st.st_mode))
+ {
+ if (flags & MU_PARSE_CONFIG_VERBOSE)
+ mu_diag_output (MU_DIAG_INFO, _("%s: not a regular file"), full_name);
+ free (full_name);
+ return ENOENT;
+ }
+
fp = fopen (full_name, "r");
if (!fp)
{
Regards,
Sergey