Hi Daniel, > SuSv3 says > "Upon successful completion, connect() shall return 0; > otherwise, -1 shall be returned and errno set to indicate the > error." > and "No function in this volume of IEEE Std 1003.1-2001 shall set > errno to 0."
This is the exact behavior I am seeing here. This suggests that, contrary to my initial expectations, connect(2) does the right thing here and distcc's assumption than it can rely on errno after connect(2) has been successful if not correct. > Thus your change should have no effect on any POSIX-compliant system. If I read you correctly, it does. The change I propose makes it possible to trust errno even if connect(2) was successful (i.e. returned 0), which wasn't the case before. > Can you dig into the problem a bit more, and see what's > really going on? There's not much I can add, is there? I described how connect(2) works on my system and that it doesn't fit in distcc's assumptions. The only point to be confirmed was on who were right, and your quotes seem to innocent my system. Let's simply apply the trivial patch I proposed and it should be fine. Thanks. -- Jean Delvare http://khali.linux-fr.org/ __ distcc mailing list http://distcc.samba.org/ To unsubscribe or change options: http://lists.samba.org/mailman/listinfo/distcc