Not working: recv made non blocking to eliminate deadlock