Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cpython
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
cpython
Commits
a33c8436
Commit
a33c8436
authored
Aug 06, 2014
by
Serhiy Storchaka
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Issue #18004: test_overflow in test_list by mistake consumed 40 GiB of memory
on 64-bit systems.
parent
501da1da
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
1 deletion
+4
-1
Lib/test/test_list.py
Lib/test/test_list.py
+1
-1
Misc/NEWS
Misc/NEWS
+3
-0
No files found.
Lib/test/test_list.py
View file @
a33c8436
...
@@ -53,7 +53,7 @@ class ListTest(list_tests.CommonTest):
...
@@ -53,7 +53,7 @@ class ListTest(list_tests.CommonTest):
def
test_overflow
(
self
):
def
test_overflow
(
self
):
lst
=
[
4
,
5
,
6
,
7
]
lst
=
[
4
,
5
,
6
,
7
]
n
=
int
((
sys
.
max
int
*
2
+
2
)
//
len
(
lst
))
n
=
int
((
sys
.
max
size
*
2
+
2
)
//
len
(
lst
))
def
mul
(
a
,
b
):
return
a
*
b
def
mul
(
a
,
b
):
return
a
*
b
def
imul
(
a
,
b
):
a
*=
b
def
imul
(
a
,
b
):
a
*=
b
self
.
assertRaises
((
MemoryError
,
OverflowError
),
mul
,
lst
,
n
)
self
.
assertRaises
((
MemoryError
,
OverflowError
),
mul
,
lst
,
n
)
...
...
Misc/NEWS
View file @
a33c8436
...
@@ -74,6 +74,9 @@ Library
...
@@ -74,6 +74,9 @@ Library
Tests
Tests
-----
-----
- Issue #18004: test_overflow in test_list by mistake consumed 40 GiB of memory
on 64-bit systems.
- Issue #21976: Fix test_ssl to accept LibreSSL version strings. Thanks
- Issue #21976: Fix test_ssl to accept LibreSSL version strings. Thanks
to William Orr.
to William Orr.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment