Thanks LRN for used functions list. Very useful analysis! Christian, "wrapper" don't require code duplication so list is not so scaring. MHD actually needs: _SetErrnoFromWinError - very simple long "switch", code can be redesigned to live without it. _win_strerror - one more long "switch", same as _SetErrnoFromWinError _win_socketpair - used instead of pipe, can be implemented as MHD_socketpair or MHD_pipe. As side effect, MHD_USE_SOKET_INSTEAD_OF_PIPE can be added to MHD (may be useful outside win32 platform) _win_mmap and _win_munmap - used only in memorypool.c and for MHD needs can be implemented in much simpler way than full-featured implementation in PlibC.
As side effect this can improve performance of MHD. Evgeny 25.01.2014, 13:03, "Christian Grothoff" <[email protected]>: > That still feels like it would be too much code to duplicate. > > My 2 cents > > Christian > > On 01/25/14 08:55, LRN wrote: >> >> _SetErrnoFromWinError - utility >> _win_accept - wrapper >> _win_bind - wrapper >> _win_close - dispatcher/wrapper >> _win_listen - wrapper >> _win_mmap - implementation >> _win_munmap - implementation >> _win_recv - wrapper >> _win_select - implementation (reducible) >> _win_send - wrapper >> _win_setsockopt - wrapper >> _win_shutdown - wrapper >> _win_socket - wrapper >> _win_socketpair - implementation >> _win_strerror - implementation >> _win_tdelete - implementation (unneded) >> _win_tfind - implementation (unneded) >> _win_tsearch - implementation (unneded) >> _win_write - wrapper >> plibc_init - utility >> plibc_shutdown - utility >> >> "wrapper" means that it calls some other function, although it may add >> some error conversion from Windows errors to errno. >> >> "implementation" means actual code and/or more than one lowlevel >> function call. >> >> "utility" is there to support plibc itself
