Skip to content

Commit

Permalink
small fix
Browse files Browse the repository at this point in the history
Small followup to #1456
  • Loading branch information
albertz committed Nov 8, 2023
1 parent ff7569f commit 9fe9359
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion returnn/util/basic.py
Original file line number Diff line number Diff line change
Expand Up @@ -2626,7 +2626,7 @@ def read_pickled_object(p: typing.BinaryIO, *, encoding=None) -> Any:
"""
from returnn.util.task_system import Unpickler

size_raw = read_bytes_to_new_buffer(p, 4)
size_raw = read_bytes_to_new_buffer(p, 4).getvalue()
(size,) = struct.unpack("<i", size_raw)
assert size > 0, "read_pickled_object: We expect to get some non-empty package."
stream = read_bytes_to_new_buffer(p, size)
Expand Down

0 comments on commit 9fe9359

Please sign in to comment.