Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(147)

Delta Between Two Patch Sets: Lib/socketserver.py

Issue 22043: Use a monotonic clock to compute timeouts
Left Patch Set: Created 3 years, 2 months ago
Right Patch Set: Created 3 years, 2 months ago
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments. Please Sign in to add in-line comments.
Jump to:
Left: Side by side diff | Download
Right: Side by side diff | Download
« no previous file with change/comment | « Lib/sched.py ('k') | Lib/subprocess.py » ('j') | no next file with change/comment »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
LEFTRIGHT
1 """Generic socket server classes. 1 """Generic socket server classes.
2 2
3 This module tries to capture the various aspects of defining a server: 3 This module tries to capture the various aspects of defining a server:
4 4
5 For socket-based servers: 5 For socket-based servers:
6 6
7 - address family: 7 - address family:
8 - AF_INET{,6}: IP (Internet Protocol) sockets (default) 8 - AF_INET{,6}: IP (Internet Protocol) sockets (default)
9 - AF_UNIX: Unix domain sockets 9 - AF_UNIX: Unix domain sockets
10 - others, e.g. AF_DECNET are conceivable (see <socket.h> 10 - others, e.g. AF_DECNET are conceivable (see <socket.h>
(...skipping 741 matching lines...) Expand 10 before | Expand all | Expand 10 after
752 """Define self.rfile and self.wfile for datagram sockets.""" 752 """Define self.rfile and self.wfile for datagram sockets."""
753 753
754 def setup(self): 754 def setup(self):
755 from io import BytesIO 755 from io import BytesIO
756 self.packet, self.socket = self.request 756 self.packet, self.socket = self.request
757 self.rfile = BytesIO(self.packet) 757 self.rfile = BytesIO(self.packet)
758 self.wfile = BytesIO() 758 self.wfile = BytesIO()
759 759
760 def finish(self): 760 def finish(self):
761 self.socket.sendto(self.wfile.getvalue(), self.client_address) 761 self.socket.sendto(self.wfile.getvalue(), self.client_address)
LEFTRIGHT

RSS Feeds Recent Issues | This issue
This is Rietveld 894c83f36cb7