I have a random piece of code, I use for reading from CSV files... and it's fine... until after about 2000 reads... then the getline line fails with an access violation to 0xcccccc... which I assume means that the input stream (file) has been cleared... Not that I know why :)

```
int CCSVManager::ReadCSVLine ( fstream * fsInputFile,
                               vector <string> * recordData )
{
    string s;

    getline ( *fsInputFile, s );
    stringstream iss( s );

    for ( unsigned int i = 0; i < getNumFields (); i++ )
    {
        getline ( iss, s, ',' );
        (*recordData)[i] = s;
    }

    return 0;
}

```

Any ideas why?