2003-10-22 Ralf Corsepius <corsepiu@faw.uni-ulm.de>

PR 509/filesystem
	* src/dosfs/fat.c: _fat_block_read and _fat_block_write return error
	codes instead of -1 in case of errors, as they are supposed to do
	according to the comments documenting these functions.
This commit is contained in:
Joel Sherrill
2003-10-22 16:35:02 +00:00
parent 843805f7a0
commit 5150ab0448
2 changed files with 10 additions and 3 deletions

View File

@@ -1,3 +1,10 @@
2003-10-22 Ralf Corsepius <corsepiu@faw.uni-ulm.de>
PR 509/filesystem
* src/dosfs/fat.c: _fat_block_read and _fat_block_write return error
codes instead of -1 in case of errors, as they are supposed to do
according to the comments documenting these functions.
2003-10-21 Ralf Corsepius <corsepiu@faw.uni-ulm.de>
* src/dosfs/msdos_file.c (msdos_file_read, msdos_file_write):

View File

@@ -64,8 +64,8 @@ _fat_block_read(
{
rc = fat_buf_access(fs_info, blk, FAT_OP_TYPE_READ, &block);
if (rc != RC_OK)
return rc;
return -1;
c = MIN(count, (fs_info->vol.bps - ofs));
memcpy((buff + cmpltd), (block->buffer + ofs), c);
@@ -119,7 +119,7 @@ _fat_block_write(
else
rc = fat_buf_access(fs_info, blk, FAT_OP_TYPE_READ, &block);
if (rc != RC_OK)
return rc;
return -1;
memcpy((block->buffer + ofs), (buff + cmpltd), c);