#include "lib.h"
+extern short Umask;
+
void mutt_nocurses_error (const char *fmt, ...)
{
va_list ap;
struct stat osb, nsb;
int fd;
- if ((fd = open (path, flags, 0600)) < 0)
+ umask(Umask);
+ if ((fd = open (path, flags, 0666)) < 0)
return fd;
/* make sure the file is not symlink */
*/
FILE *safe_fopen (const char *path, const char *mode)
{
+ /* first set the current umask */
+ umask(Umask);
if (mode[0] == 'w')
{
int fd;