search for: current_umask

Displaying 3 results from an estimated 3 matches for "current_umask".

2012 Feb 10
0
[PATCH] btrfs: honor umask when creating subvol root
...struct btrfs_trans_handle *trans, int err; u64 index = 0; - inode = btrfs_new_inode(trans, new_root, NULL, "..", 2, new_dirid, - new_dirid, S_IFDIR | 0700, &index); + inode = btrfs_new_inode(trans, new_root, NULL, "..", 2, + new_dirid, new_dirid, + S_IFDIR | (~current_umask() & S_IRWXUGO), + &index); if (IS_ERR(inode)) return PTR_ERR(inode); inode->i_op = &btrfs_dir_inode_operations; -- 1.7.8.4 -- To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in the body of a message to majordomo@vger.kernel.org More majord...
2012 May 18
0
[LLVMdev] [RFC] llvm/include/Support/FileOutputBuffer.h
...52,6 +55,7 @@ > # define PATH_MAX 4096 > #endif > > + > using namespace llvm; > > namespace { > @@ -347,10 +351,19 @@ > return error_code::success(); > } > > -// Since this is most often used for temporary files, mode defaults to 0600. > +static mode_t current_umask() { > + // There is no posix way to just get current umask. You > + // have to set it to something else, and get the "old" value. > + // So, get and reset to get the current umask value; > + mode_t mask = ::umask(0); > + ::umask(mask); > + return mask; > +} &gt...
2012 May 17
3
[LLVMdev] [RFC] llvm/include/Support/FileOutputBuffer.h
I now have an implementation of FileOutputBuffer (OutputBuffer was already taken). The patch supports the functionality listed below and I've tested that it works for lld. -------------- next part -------------- A non-text attachment was scrubbed... Name: FileOutputBuffer.patch Type: application/octet-stream Size: 25308 bytes Desc: not available URL: