使用
fs.chmod(path, mode, callback)
函数将文件夹或文件的访问权限设置为777
时,并未能正确生效。但当将其设置为0777
时,权限设置才会生效。
所以我想知道chmod 777
和chmod 0777
之间有何区别?