Skip to content
Merged
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
6 changes: 3 additions & 3 deletions qiling/os/posix/syscall/unistd.py
Original file line number Diff line number Diff line change
Expand Up @@ -766,7 +766,7 @@ def _type_mapping(ent):
return bytes([t])

if ql.os.fd[fd].tell() == 0:
n = ql.arch.pointersize
n = 8 if is_64 else ql.arch.pointersize
total_size = 0
results = os.scandir(ql.os.fd[fd].name)
_ent_count = 0
Expand All @@ -787,8 +787,8 @@ def _type_mapping(ent):

if is_64:
fields = (
(ql.pack(d_ino), n),
(ql.pack(d_off), n),
(ql.pack64(d_ino), n),
(ql.pack64(d_off), n),
(ql.pack16(d_reclen), 2),
(d_type, 1),
(d_name, len(d_name))
Expand Down