Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chmod() doesn't pass a callback function? #35

Open
TooTallNate opened this issue Apr 27, 2015 · 1 comment · May be fixed by #36
Open

chmod() doesn't pass a callback function? #35

TooTallNate opened this issue Apr 27, 2015 · 1 comment · May be fixed by #36

Comments

@TooTallNate
Copy link

I'm getting strange behavior when trying to implement the chmod() function. It only gets passed 2 arguments it seems, the path and mode. But the callback function (expected as 3rd argument) is not there! See log:

  s3fs GETATTR: path='/' key='/' +3s
  s3fs GETATTR: path='/cron.sh' key='/cron.sh' +1ms
  s3fs GETATTR: path='/cron.sh' key='/cron.sh' +66ms
{ '0': '/cron.sh', '1': 33261 }
  s3fs CHMOD: path='/cron.sh' mode=33261 +61ms
chmod() does not pass a cb() function... wtf

Where the code looks something like this (basically a no-op, just with some logging):

function chmod(path, mode, cb) {
  console.error(arguments);
  debug('CHMOD: path=%o mode=%o', path, mode);

  if (cb)
    return cb(0);
  else
    console.error('chmod() does not pass a cb() function... wtf');
}

Any idea what's going on here? Thanks in advance.

/cc @gierschv @bcle

TooTallNate added a commit to TooTallNate/fuse4js that referenced this issue Apr 27, 2015
Fixes bcle#35.

It also looks like a few of these other OP's might also need this same treatment (i.e. "truncate"), though I haven't yet tested to verify that.
@TooTallNate TooTallNate linked a pull request Apr 27, 2015 that will close this issue
@TooTallNate
Copy link
Author

I think #36 fixes it…

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant