I want to have a reader thread & a writer thread to same TCP socket. Is it ok? Do I need to lock before accessing it ? Platform is Windows 7, CPython 2.7.4
相关问题
- how to define constructor for Python's new Nam
- streaming md5sum of contents of a large remote tar
- How to get the background from multiple images by
- Evil ctypes hack in python
- Correctly parse PDF paragraphs with Python
For Unix kernel two threads one reading and other writing to a file (socket) is same as two processes doing the same. As the kernel is capable of Multiplexing the IO you don't need to worry.