1789 } |
1797 } |
1790 |
1798 |
1791 if(dir->metadata & FINFO_XATTR == FINFO_XATTR) { |
1799 if(dir->metadata & FINFO_XATTR == FINFO_XATTR) { |
1792 char *path = util_concat_path(dir->path, db_res->path); |
1800 char *path = util_concat_path(dir->path, db_res->path); |
1793 XAttributes *xattr = file_get_attributes(path); |
1801 XAttributes *xattr = file_get_attributes(path); |
|
1802 // test if xattr are added, removed or changed |
1794 if((db_res->xattr_hash && !xattr) || |
1803 if((db_res->xattr_hash && !xattr) || |
1795 (!db_res->xattr_hash && xattr) || |
1804 (!db_res->xattr_hash && xattr) || |
1796 strcmp(xattr->hash, db_res->xattr_hash)) |
1805 (xattr && db_res->xattr_hash && strcmp(xattr->hash, db_res->xattr_hash))) |
1797 { |
1806 { |
1798 res->metadata_updated = 1; |
1807 res->metadata_updated = 1; |
1799 res->xattr_updated = 1; |
1808 res->xattr_updated = 1; |
1800 res->xattr = xattr; |
1809 res->xattr = xattr; |
1801 } else if(xattr) { |
1810 } else if(xattr) { |