From: Charlie Savage Date: 2009-02-16T07:40:51+09:00 Subject: [ruby-core:22170] [Bug #1162] Build Assertion Failure with VC+++ - Incorrect flushing of stdout/stderr Issue #1162 has been updated by Charlie Savage. Hi Nobu, Thanks for your help on this. However, I think your patch is the wrong approach. If I understand the intention correctly, it is meant to stub out all crt debug messages. Is such a strong remedy needed to solve this one issue? Take for example the other VC++ bug I submitted about the unassigned variable - your patch would hide it (assuming I am understanding the patch correctly). Or what about more serious issues such as using ALLOC in tandem with free instead of xfree on the Windows platform? Do we want to disable those also? The other problem with the patch is that it doesn't actually work. To test it I applied to locally. The assertion error does not go away and it still not possible to build Ruby with the -RTC1 flag. So would you be willing to revert this patch? As for the original problem, I'll make my pitch one more time and then if you still disagree I'll just have to patch my own version of ruby 1.9.1. Quoting MSDN - http://msdn.microsoft.com/en-us/library/aa364439(VS.85).aspx. "The function fails if hFile is a handle to the console output. That is because the console output is not buffered. The function returns FALSE, and GetLastError returns ERROR_INVALID_HANDLE." Seeing that Microsoft's documentation says it invalid to pass stdout or stderr to FlushFileBuffers, and _commit calls FlushFileBuffers, I have a hard time seeing that this is a bug in msvcrt. ---------------------------------------- http://redmine.ruby-lang.org/issues/show/1162 ---------------------------------------- http://redmine.ruby-lang.org