summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar Dave Nicolson2026-03-30 20:21:22 +0200
committerGravatar GitHub2026-03-30 20:21:22 +0200
commitf41b1ea67045e0c09339974d83e389972d84f166 (patch)
tree65f479bb3a3c4718b4e5e32c70f70b6891b9c744
parentc8b36a80bad4a1fe488927af4da0ecbcf10079bb (diff)
downloadlibplist-f41b1ea67045e0c09339974d83e389972d84f166.tar.gz
libplist-f41b1ea67045e0c09339974d83e389972d84f166.tar.bz2
Fix Cython crashesHEADmaster
-rw-r--r--cython/plist.pyx5
1 files changed, 4 insertions, 1 deletions
diff --git a/cython/plist.pyx b/cython/plist.pyx
index 29c1181..73912d8 100644
--- a/cython/plist.pyx
+++ b/cython/plist.pyx
@@ -789,7 +789,10 @@ cdef class Array(Node):
return self._array.__iter__()
def __getitem__(self, index):
- return self._array[index]
+ value = self._array[index]
+ if isinstance(value, list):
+ return [item.copy() for item in value]
+ return value.copy()
def __setitem__(self, index, value):
cdef Node n