| 411 | } |
| 412 | |
| 413 | U32 PosixFile::read(void* dst, U32 size) |
| 414 | { |
| 415 | if (_status != Open && _status != EndOfFile) |
| 416 | return 0; |
| 417 | |
| 418 | U32 bytesRead = fread(dst, 1, size, _handle); |
| 419 | |
| 420 | if (bytesRead != size) |
| 421 | { |
| 422 | if (feof(_handle)) |
| 423 | _status = EndOfFile; |
| 424 | else |
| 425 | _updateStatus(); |
| 426 | } |
| 427 | |
| 428 | return bytesRead; |
| 429 | } |
| 430 | |
| 431 | U32 PosixFile::write(const void* src, U32 size) |
| 432 | { |
nothing calls this directly
no test coverage detected