You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

23 lines
701 B

const Fuse = require('fuse-native')
const Errors = require('../../shared/Errors')
const Message = require('../../shared/Message')
const connector = require('../connector')
module.exports = exports = function (path, name, value, position, flags, cb) {
connector.send(
Message.route('fs.xattr.set')
.data({
path,
name,
value: value.toString('base64'), // value is a Buffer of binary data
})
.expect_response(msg => {
if ( msg.error() ) {
return Errors.toCallback(cb, msg.error())
}
return process.nextTick(cb, 0)
})
)
}