[Fix #58] Correctly deal with fd blocking