]> git.ipfire.org Git - thirdparty/snapper.git/commitdiff
- renamed enum member to match linux vocabulary
authorArvin Schnell <aschnell@suse.de>
Wed, 26 Feb 2014 13:17:47 +0000 (14:17 +0100)
committerArvin Schnell <aschnell@suse.de>
Wed, 26 Feb 2014 13:17:47 +0000 (14:17 +0100)
snapper/Btrfs.cc
snapper/Compare.cc
snapper/File.cc
snapper/File.h

index 7335615280d39bf3861b1864197a691872e33ce5..cc0ba86fc4443d87178d1719dd503ed1692a164d 100644 (file)
@@ -451,10 +451,10 @@ namespace snapper
        if (status & CREATED) status = CREATED;
        if (status & DELETED) status = DELETED;
 
-       if (status & (CONTENT | PERMISSIONS | USER | GROUP | XATTRS | ACL))
+       if (status & (CONTENT | PERMISSIONS | OWNER | GROUP | XATTRS | ACL))
        {
            // TODO check for content sometimes not required
-           status &= ~(CONTENT | PERMISSIONS | USER | GROUP | XATTRS | ACL);
+           status &= ~(CONTENT | PERMISSIONS | OWNER | GROUP | XATTRS | ACL);
 
            string dirname = snapper::dirname(name);
            string basename = snapper::basename(name);
@@ -547,7 +547,7 @@ namespace snapper
        else
        {
            node->status &= ~(CREATED | DELETED);
-           node->status |= CONTENT | PERMISSIONS | USER | GROUP | XATTRS | ACL;
+           node->status |= CONTENT | PERMISSIONS | OWNER | GROUP | XATTRS | ACL;
        }
     }
 
@@ -680,7 +680,7 @@ namespace snapper
                else
                {
                    node->status &= ~(CREATED | DELETED);
-                   node->status |= CONTENT | PERMISSIONS | USER | GROUP | XATTRS | ACL;
+                   node->status |= CONTENT | PERMISSIONS | OWNER | GROUP | XATTRS | ACL;
                }
 
                merge(processor, &it->second, from, to, x);
@@ -698,7 +698,7 @@ namespace snapper
                else
                {
                    node->status &= ~(CREATED | DELETED);
-                   node->status |= CONTENT | PERMISSIONS | USER | GROUP | XATTRS | ACL;
+                   node->status |= CONTENT | PERMISSIONS | OWNER | GROUP | XATTRS | ACL;
                }
 
                merge(processor, &it->second, from, to, x);
@@ -937,7 +937,7 @@ namespace snapper
 #endif
 
        tree_node* node = processor->files.insert(path);
-       node->status |= USER | GROUP;
+       node->status |= OWNER | GROUP;
 
        return 0;
     }
index fa1b771e30d3e03fd77dbcd966cabf07b484c909..cd21a299c8d78cb3d0716e5328f8759fe1815610 100644 (file)
@@ -212,7 +212,7 @@ namespace snapper
 
        if (stat1.st_uid != stat2.st_uid)
        {
-           status |= USER;
+           status |= OWNER;
        }
 
        if (stat1.st_gid != stat2.st_gid)
index 7865ffb8b0e1b792942a249206f2e07ce153530f..b328c73ded41b0d6a465b0bf8f6407338f6d0ecd 100644 (file)
@@ -514,7 +514,7 @@ namespace snapper
                }
            }
 
-           if (getPreToPostStatus() & (USER | GROUP))
+           if (getPreToPostStatus() & (OWNER | GROUP))
            {
                if (lchown(getAbsolutePath(LOC_SYSTEM).c_str(), fs.st_uid, fs.st_gid) != 0)
                {
@@ -636,7 +636,7 @@ namespace snapper
                error = true;
        }
 
-       if (getPreToPostStatus() & (CONTENT | PERMISSIONS | USER | GROUP))
+       if (getPreToPostStatus() & (CONTENT | PERMISSIONS | OWNER | GROUP))
        {
            if (!modifyAllTypes())
                error = true;
@@ -756,7 +756,7 @@ namespace snapper
            ret += ".";
 
        ret += status & PERMISSIONS ? "p" : ".";
-       ret += status & USER ? "u" : ".";
+       ret += status & OWNER ? "u" : ".";
        ret += status & GROUP ? "g" : ".";
        ret += status & XATTRS ? "x" : ".";
        ret += status & ACL ? "a" : ".";
@@ -789,8 +789,8 @@ namespace snapper
 
        if (str.length() >= 3)
        {
-           if (str[2] == 'u')
-               ret |= USER;
+           if (str[2] == 'u' || str[2] == 'o')
+               ret |= OWNER;
        }
 
        if (str.length() >= 4)
index 96c1e39e8d743198b41e5c1beb9971e156cc7ba7..b6783f335d376abaac02c517aba05d28ee6e5406 100644 (file)
@@ -38,7 +38,7 @@ namespace snapper
 
     enum StatusFlags
     {
-       CREATED = 1, DELETED = 2, TYPE = 4, CONTENT = 8, PERMISSIONS = 16, USER = 32,
+       CREATED = 1, DELETED = 2, TYPE = 4, CONTENT = 8, PERMISSIONS = 16, OWNER = 32, USER = 32,
        GROUP = 64, XATTRS = 128, ACL = 256
     };