Pipes are probably the simplest and most common example of asynchronous communication between processes...
Where did you find the "if and only if"? Note: by 'p' above I meant the 'git cat-file' subprocess - not the Python class wrapper around it. 2014-03-27 1:33 GMT+00:00 Karl Wiberg <[email protected]>: > On Wed, Mar 26, 2014 at 4:22 PM, Marc Herbert > <[email protected]> wrote: >> 2014-03-16 21:16 GMT+00:00 Sima Baymani <[email protected]>: >>> + p.stdin.close() >>> os.kill(p.pid(), signal.SIGTERM) >>> p.wait() >> >> Note this looks like very much like creating a race condition: p will >> be interrupted at a random point in time while trying to deal with the >> closure. It could be harmless - sorry don't know enough to tell. > > Really? I'd expect .close() to be synchronous---how else could it > raise exceptions if and only if there was a problem? > > -- > Karl Wiberg, [email protected] > subrabbit.wordpress.com > www.treskal.com/kalle _______________________________________________ stgit-users mailing list [email protected] https://mail.gna.org/listinfo/stgit-users
