# # patch "ChangeLog" # from [b5ce0e31b5552a26f01d17edf46fad8271e87227] # to [dc631b0fd1d9bf355497521d61f0eaa173534dd4] # # patch "configure.ac" # from [df78b3726a6727dc09ca4573281ddb103dc79d56] # to [b2c3219e2a140dbc47379fd23cae0e918e5e71cc] # # patch "ui.cc" # from [956b7c37e04eab186d093e34b39a625b7264849a] # to [c51b1607975f692479563b70efd80c40731ea83a] # ======================================================================== --- ChangeLog b5ce0e31b5552a26f01d17edf46fad8271e87227 +++ ChangeLog dc631b0fd1d9bf355497521d61f0eaa173534dd4 @@ -1,3 +1,10 @@ +2005-11-27 Julio M. Merino Vidal
+ + * configure.ac, ui.cc: Windows does have sync_with_iostream; the + problem is that it does not behave correctly on some MinGW versions. + Properly detect this condition. Thanks to Matthew Gregan for the + explanation. + 2005-11-27 Matthew Gregan * tests/t_netsync_largish_file.at: Move LARGISH_FILE_CREATE ======================================================================== --- configure.ac df78b3726a6727dc09ca4573281ddb103dc79d56 +++ configure.ac b2c3219e2a140dbc47379fd23cae0e918e5e71cc @@ -471,21 +471,67 @@ AC_CHECK_FUNC(getaddrinfo, [AM_CONDITIONAL(MISSING_GETADDRINFO, false)], [AM_CONDITIONAL(MISSING_GETADDRINFO, true)]) -# Check whether C++ streams support sync_with_stdio. +# Check whether sync_with_stdio(false) run on C++ streams works correctly. +# It causes strange problems (EOF returned too early) on some versions of +# MinGW. +# +# In order to check for this issue, we first generate a large input file +# (over 128KB) and then try to read it (using a buffer size over 512 +# bytes). If the amount of bytes read does not match the generated input, +# the implementation is broken. AC_MSG_CHECKING(whether C++ streams support sync_with_stdio) -AC_LINK_IFELSE([AC_LANG_SOURCE([ +AC_RUN_IFELSE([AC_LANG_SOURCE([ +/* + * Generates the input file. + */ +#include