Fix minor windows pedantic warnings.

This commit is contained in:
Jason Felds
2016-03-27 21:52:05 -04:00
parent 534909d30a
commit bec18a0d36
31 changed files with 173 additions and 67 deletions
+7 -3
View File
@@ -327,12 +327,13 @@ int RageFileObj::GetLine( RString &sOut )
sOut = "";
if( m_bEOF )
{
return 0;
}
EnableReadBuffering();
bool bGotData = false;
while( 1 )
for(;;)
{
bool bDone = false;
@@ -361,12 +362,15 @@ int RageFileObj::GetLine( RString &sOut )
{
char *RealEnd = p;
if( bDone && p > m_pReadBuf && p[-1] == '\r' )
{
--RealEnd; /* not including \r */
}
sOut.append( m_pReadBuf, RealEnd );
if( bDone )
{
++p; /* skip \n */
}
const int iUsed = p-m_pReadBuf;
if( iUsed )
{