Hi,

seems like I found the solution. The problem is that registerSocket() in platform/emulator/os.cc is not always working. One solution is to #define FD_SETSIZE 1024 in wsock.hh before winsock.h is includes (the default value is 64, which is too small when you consider the way fd_set is used in os.cc). 1024 is Linux default, so I think it's ok this way. The code snippet that I posted earlier does work without problems after this change.

However, I still think that using the FD_XXX macros is a bad solution to this trivial problem. I tried to change the implementation to use std::set instead (I know that this might not be the most efficient solution, but it's not that bad). The problem is that I'd have to change linker settings to link C++ stdlib instead of C, which I am not sure is what I want...

Cheers,
Filip

_________________________________________________________________________________
mozart-hackers mailing list [email protected] http://www.mozart-oz.org/mailman/listinfo/mozart-hackers

Reply via email to