Permissions: Fix missing initialization with 0 in some cases

这个提交包含在:
Albert S. 2019-10-02 23:36:30 +02:00
父节点 1549603c9b
当前提交 21834b2414
共有 2 个文件被更改,包括 2 次插入1 次删除

查看文件

@ -27,6 +27,7 @@ Permissions::Permissions(int permissions)
Permissions::Permissions(const std::string &str)
{
this->permissions = 0;
for(auto permission : permmap)
{
if(str.find(permission.first) != std::string::npos)

查看文件

@ -17,7 +17,7 @@
class Permissions
{
private:
int permissions;
int permissions = 0;
const std::map<std::string, int> permmap =
{
{ "can_read", PERM_CAN_READ },