We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 0d0013b commit 1bccec5Copy full SHA for 1bccec5
mfusepy.py
@@ -1507,7 +1507,8 @@ def _readdir(self, path: Optional[bytes], buf, filler, offset: int, fip) -> int:
1507
if isinstance(item, bytes):
1508
name, st, offset = item, None, 0
1509
else:
1510
- name, attrs, offset = item
+ name_str, attrs, offset = item
1511
+ name = name_str.encode(self.encoding)
1512
if attrs:
1513
st = c_stat()
1514
# ONLY THE MODE IS USED BY FUSE! The caller may skip everything else.
@@ -1517,10 +1518,10 @@ def _readdir(self, path: Optional[bytes], buf, filler, offset: int, fip) -> int:
1517
1518
st = None
1519
1520
if fuse_version_major == 2:
- if filler(buf, name.encode(self.encoding), st, offset) != 0: # type: ignore
1521
+ if filler(buf, name, st, offset) != 0: # type: ignore
1522
break
1523
elif fuse_version_major == 3:
- if filler(buf, name.encode(self.encoding), st, offset, 0) != 0:
1524
+ if filler(buf, name, st, offset, 0) != 0:
1525
1526
1527
return 0
0 commit comments