git » pymisc » master » tree

[master] / samples / pcmp / sample1.py

import os
import pcmp

c = pcmp.Channel()

pid = os.fork()
if pid == 0:
	c.child()
	c.send('Hola papi!')
	print c.recv()
else:
	c.parent()
	c.send("Hola hijito!")
	print c.recv()
	os.wait()