Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
P
pyfs
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
OpenEdx
pyfs
Commits
72b8884b
Commit
72b8884b
authored
Jun 16, 2009
by
rfkelly0
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
expose.fuse: avoid need to simulate xattr support
parent
b95b6dc5
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
5 deletions
+3
-5
fs/expose/fuse/__init__.py
+3
-5
No files found.
fs/expose/fuse/__init__.py
View file @
72b8884b
...
@@ -55,7 +55,6 @@ import pickle
...
@@ -55,7 +55,6 @@ import pickle
from
fs.base
import
flags_to_mode
,
threading
from
fs.base
import
flags_to_mode
,
threading
from
fs.errors
import
*
from
fs.errors
import
*
from
fs.path
import
*
from
fs.path
import
*
from
fs.xattrs
import
ensure_xattrs
import
fuse_ctypes
as
fuse
import
fuse_ctypes
as
fuse
try
:
try
:
...
@@ -126,7 +125,7 @@ class FSOperations(Operations):
...
@@ -126,7 +125,7 @@ class FSOperations(Operations):
"""FUSE Operations interface delegating all activities to an FS object."""
"""FUSE Operations interface delegating all activities to an FS object."""
def
__init__
(
self
,
fs
,
on_init
=
None
,
on_destroy
=
None
):
def
__init__
(
self
,
fs
,
on_init
=
None
,
on_destroy
=
None
):
self
.
fs
=
ensure_xattrs
(
fs
)
self
.
fs
=
fs
self
.
_on_init
=
on_init
self
.
_on_init
=
on_init
self
.
_on_destroy
=
on_destroy
self
.
_on_destroy
=
on_destroy
self
.
_fhmap
=
{}
self
.
_fhmap
=
{}
...
@@ -184,8 +183,7 @@ class FSOperations(Operations):
...
@@ -184,8 +183,7 @@ class FSOperations(Operations):
try
:
try
:
value
=
self
.
fs
.
getxattr
(
path
,
name
)
value
=
self
.
fs
.
getxattr
(
path
,
name
)
except
AttributeError
:
except
AttributeError
:
# TODO: raise ENODATA, avoid the need for ensure_xattrs
raise
OSError
(
errno
.
ENODATA
,
"no attribute '
%
s'"
%
(
name
,))
raise
UnsupportedError
(
"getxattr"
)
else
:
else
:
if
value
is
None
:
if
value
is
None
:
raise
OSError
(
errno
.
ENODATA
,
"no attribute '
%
s'"
%
(
name
,))
raise
OSError
(
errno
.
ENODATA
,
"no attribute '
%
s'"
%
(
name
,))
...
@@ -200,7 +198,7 @@ class FSOperations(Operations):
...
@@ -200,7 +198,7 @@ class FSOperations(Operations):
try
:
try
:
return
self
.
fs
.
listxattrs
(
path
)
return
self
.
fs
.
listxattrs
(
path
)
except
AttributeError
:
except
AttributeError
:
r
aise
UnsupportedError
(
"listxattr"
)
r
eturn
[]
@handle_fs_errors
@handle_fs_errors
def
mkdir
(
self
,
path
,
mode
):
def
mkdir
(
self
,
path
,
mode
):
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment