25.01.2014, 18:05, "LRN" <[email protected]>: > Actually, i meant the error-handling code. Imagine you've called > accept(), and want to check the errno for possible errors. But WS2 > version of accept() doesn't set errno, it sets LastError. You need to > convert LastError to errno, otherwise your errno check won't work. > Adding conversion function call after the function call might work in > some (most, actually) cases, if it's hidden under a platform-specific > macro that expands to nothing on non-W32 platforms, but using it might > be error-prone (not doing this call will result in subtle runtime > behaviour change that will be difficult to catch, and only affects W32).
Only small subset of functions really need LastError -> errno conversion. And select() and accept() are macroses already. So we are talking about removal of most wrappers and move smaller number of wrappers from PlibC to MHD code. I believe that this will improve code quality.
