Producer consumer problem