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

Ignore system mount options #192

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions gdrivefs/gdfuse.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
import pprint
import math

from errno import ENOENT, EIO, ENOTDIR, ENOTEMPTY, EPERM, EEXIST
from errno import ENOENT, EIO, EISDIR, ENOTDIR, ENOTEMPTY, EPERM, EEXIST
from fuse import FUSE, Operations, FuseOSError, c_statvfs, fuse_get_context, \
LoggingMixIn
from time import mktime, time
Expand Down Expand Up @@ -697,7 +697,7 @@ def unlink(self, file_path):
_logger.error("Can not unlink() directory [%s] with ID [%s]. "
"Must be file.", file_path, entry_id)

raise FuseOSError(errno.EISDIR)
raise FuseOSError(EISDIR)

# Remove online. Complements local removal (if not found locally, a
# follow-up request checks online).
Expand Down Expand Up @@ -839,7 +839,8 @@ def mount(auth_storage_filepath, mountpoint, debug=None, nothreads=None,
_logger.debug("Forwarding option [%s] with value [%s] to "
"FUSE.", k, v)

fuse_opts[k] = v
if k not in ('user', '_netdev'):
fuse_opts[k] = v

if gdrivefs.config.IS_DEBUG is True:
_logger.debug("FUSE options:\n%s", pprint.pformat(fuse_opts))
Expand Down