parent
e38cb3ed30
commit
ecc35f94f6
@ -0,0 +1,20 @@
|
||||
const Fuse = require('fuse-native')
|
||||
const Errors = require('../../shared/Errors')
|
||||
const Message = require('../../shared/Message')
|
||||
const connector = require('../connector')
|
||||
|
||||
module.exports = exports = function (path, fd, cb) {
|
||||
console.log('[FLUSH]')
|
||||
connector.send(
|
||||
Message.route('fs.flush')
|
||||
.data({ path, descriptor: fd })
|
||||
.expect_response(msg => {
|
||||
if ( msg.error() ) {
|
||||
return Errors.toCallback(cb, msg.error())
|
||||
}
|
||||
|
||||
console.log('[/FLUSH]')
|
||||
return process.nextTick(cb, 0)
|
||||
})
|
||||
)
|
||||
}
|
Loading…
Reference in new issue