Permalink
Browse files

removed umask calls in lfs.mkdir, see kepler-list message from Enrico…

… at 2009-12-27
  • Loading branch information...
Fabio Mascarenhas
Fabio Mascarenhas committed Dec 29, 2009
1 parent 8ff2013 commit fd028d32578fa0b7d5dfc89345f851b02a5af196
Showing with 0 additions and 3 deletions.
  1. +0 −3 src/lfs.c
View
@@ -367,10 +367,8 @@ static int make_dir (lua_State *L) {
const char *path = luaL_checkstring (L, 1);
int fail;
#ifdef _WIN32
int oldmask = umask (0);
fail = _mkdir (path);
#else
mode_t oldmask = umask( (mode_t)0 );
fail = mkdir (path, S_IRUSR | S_IWUSR | S_IXUSR | S_IRGRP |
S_IWGRP | S_IXGRP | S_IROTH | S_IXOTH );
#endif
@@ -379,7 +377,6 @@ static int make_dir (lua_State *L) {
lua_pushfstring (L, "%s", strerror(errno));
return 2;
}
umask (oldmask);
lua_pushboolean (L, 1);
return 1;
}

0 comments on commit fd028d3

Please sign in to comment.