Method setxattr()
- Method setxattr
voidsetxattr(stringfile,stringattr,stringvalue,intflags,void|boolsymlink)- Description
Set the attribute
attrto the valuevalue.The flags parameter can be used to refine the semantics of the operation.
Stdio.XATTR_CREATE specifies a pure create, which fails if the named attribute exists already.
Stdio.XATTR_REPLACE specifies a pure replace operation, which fails if the named attribute does not already exist.
By default (no flags), the extended attribute will be created if need be, or will simply replace the value if the attribute exists.
- Returns
1 if successful, 0 otherwise, setting errno.