| 146 | } |
| 147 | |
| 148 | const U8 *FileObject::readLine() |
| 149 | { |
| 150 | if(!mFileBuffer) |
| 151 | return (U8 *) ""; |
| 152 | |
| 153 | U32 tokPos = mCurPos; |
| 154 | |
| 155 | for(;;) |
| 156 | { |
| 157 | if(mCurPos == mBufferSize) |
| 158 | break; |
| 159 | |
| 160 | if(mFileBuffer[mCurPos] == '\r') |
| 161 | { |
| 162 | mFileBuffer[mCurPos++] = 0; |
| 163 | if(mFileBuffer[mCurPos] == '\n') |
| 164 | mCurPos++; |
| 165 | break; |
| 166 | } |
| 167 | |
| 168 | if(mFileBuffer[mCurPos] == '\n') |
| 169 | { |
| 170 | mFileBuffer[mCurPos++] = 0; |
| 171 | break; |
| 172 | } |
| 173 | |
| 174 | mCurPos++; |
| 175 | } |
| 176 | |
| 177 | return mFileBuffer + tokPos; |
| 178 | } |
| 179 | |
| 180 | void FileObject::peekLine( S32 peekLineOffset, U8* line, S32 length ) |
| 181 | { |
no outgoing calls
no test coverage detected