8000 gh-111803: Support loading more deeply nested lists in binary plist f… · python/cpython@2dfbdd0 · GitHub
[go: up one dir, main page]

Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 2dfbdd0

Browse files
gh-111803: Support loading more deeply nested lists in binary plist format
It no longer uses the C stack and the depth of nesting is only limited by Python recursion limit setting.
1 parent 21f83ef commit 2dfbdd0

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

Lib/plistlib.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -600,7 +600,8 @@ def _read_object(self, ref):
600600
obj_refs = self._read_refs(s)
601601
result = []
602602
self._objects[ref] = result
603-
result.extend(self._read_object(x) for x in obj_refs)
603+
for x in obj_refs:
604+
result.append(self._read_object(x))
604605

605606
# tokenH == 0xB0 is documented as 'ordset', but is not actually
606607
# implemented in the Apple reference code.
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
:mod:`plistlib` now supports loading more deeply nested lists in binary
2+
format.

0 commit comments

Comments
 (0)
0