Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gevent
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
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
gevent
Commits
6a101b46
Commit
6a101b46
authored
Apr 21, 2012
by
Denis Bilenko
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Timeout: use ref=False when creating a timer
parent
598c3787
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
4 deletions
+3
-4
gevent/timeout.py
gevent/timeout.py
+3
-4
No files found.
gevent/timeout.py
View file @
6a101b46
...
...
@@ -86,10 +86,9 @@ class Timeout(BaseException):
def
__init__
(
self
,
seconds
=
None
,
exception
=
None
):
self
.
seconds
=
seconds
self
.
exception
=
exception
if
seconds
is
not
None
:
self
.
timer
=
get_hub
().
loop
.
timer
(
seconds
)
else
:
self
.
timer
=
get_hub
().
loop
.
timer
(
0.0
)
self
.
timer
=
get_hub
().
loop
.
timer
(
seconds
or
0.0
,
ref
=
False
)
# we pass ref=False so that gevent.run() ignores oustanding timeouts
# we can do that because timeouts are always used with some other watchers
def
start
(
self
):
"""Schedule the timeout."""
...
...
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