Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Z
ZODB
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
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Kirill Smelkov
ZODB
Commits
782bd729
Commit
782bd729
authored
Mar 23, 2004
by
Stephan Richter
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
parent
854429d2
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
3 deletions
+6
-3
trunk/src/ThreadedAsync/LoopCallback.py
trunk/src/ThreadedAsync/LoopCallback.py
+6
-3
No files found.
trunk/src/ThreadedAsync/LoopCallback.py
View file @
782bd729
...
@@ -25,7 +25,7 @@ register_loop_callback() to register interest. When the mainloop
...
@@ -25,7 +25,7 @@ register_loop_callback() to register interest. When the mainloop
thread calls loop(), each registered callback will be called with the
thread calls loop(), each registered callback will be called with the
socket map as its first argument.
socket map as its first argument.
"""
"""
__version__
=
'$Revision: 1.1
2
$'
[
11
:
-
2
]
__version__
=
'$Revision: 1.1
3
$'
[
11
:
-
2
]
import
asyncore
import
asyncore
import
select
import
select
...
@@ -150,6 +150,9 @@ def loop(timeout=30.0, use_poll=0, map=None):
...
@@ -150,6 +150,9 @@ def loop(timeout=30.0, use_poll=0, map=None):
except that it also triggers ThreadedAsync callback functions
except that it also triggers ThreadedAsync callback functions
before starting the loop.
before starting the loop.
"""
"""
global
exit_status
exit_status
=
None
if
use_poll
:
if
use_poll
:
if
hasattr
(
select
,
'poll'
):
if
hasattr
(
select
,
'poll'
):
poll_fun
=
asyncore
.
poll3
poll_fun
=
asyncore
.
poll3
...
@@ -162,7 +165,7 @@ def loop(timeout=30.0, use_poll=0, map=None):
...
@@ -162,7 +165,7 @@ def loop(timeout=30.0, use_poll=0, map=None):
map
=
asyncore
.
socket_map
map
=
asyncore
.
socket_map
_start_loop
(
map
)
_start_loop
(
map
)
while
map
:
while
map
and
exit_status
is
None
:
poll_fun
(
timeout
,
map
)
poll_fun
(
timeout
,
map
)
_stop_loop
()
_stop_loop
()
...
...
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