avoid DEBUG duplicate newline

This commit is contained in:
Geoff McLane 2016-04-03 17:54:46 +02:00
parent 3e5e07ea18
commit 7598fdfff2

View file

@ -87,7 +87,16 @@ void TIDY_CALL TY_(filesink_putByte)( void* sinkData, byte bv )
fputc( bv, fout ); fputc( bv, fout );
#if !defined(NDEBUG) && defined(_MSC_VER) #if !defined(NDEBUG) && defined(_MSC_VER)
if (_fileno(fout) != 2) if (_fileno(fout) != 2)
{
if (bv != 0x0d)
{
/*\
* avoid duplicate newline - SPRTF will translate an 0x0d to CRLF,
* and do the same with the following 0x0a
\*/
SPRTF("%c",bv); SPRTF("%c",bv);
}
}
#endif #endif
} }