summaryrefslogtreecommitdiffstats
path: root/src/rfs_dir.c
diff options
context:
space:
mode:
authorChristophe Grenier <grenier@cgsecurity.org>2009-01-31 17:07:08 +0100
committerChristophe Grenier <grenier@cgsecurity.org>2009-01-31 17:07:08 +0100
commit56d98fd7a229c8839a364a8a194c89c8fa650fff (patch)
treefabc87d58b2ea35831496d5f9762f6b64b481072 /src/rfs_dir.c
parent9970a484b6983cbf5659ebf17335b4192065025e (diff)
Use pread() and pwrite() argument style for internal I/O
Diffstat (limited to 'src/rfs_dir.c')
-rw-r--r--src/rfs_dir.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/rfs_dir.c b/src/rfs_dir.c
index 9772cad..9c76fd2 100644
--- a/src/rfs_dir.c
+++ b/src/rfs_dir.c
@@ -132,7 +132,7 @@ static int file_read(dal_t *dal, void *buff, blk_t block, blk_t count) {
blocklen = count * dal->blocksize;
#endif
/* log_debug("blocklen=%ld\n",blocklen); */
- if(my_data->disk_car->read(my_data->disk_car,blocklen,buff,my_data->partition->part_offset+off))
+ if(my_data->disk_car->pread(my_data->disk_car, buff, blocklen, my_data->partition->part_offset + off) != blocklen)
return 0;
return 1;
}
@@ -151,7 +151,7 @@ static int file_write(dal_t *dal, void *buff, blk_t block, blk_t count)
off = (uint64_t)block * (uint64_t)dal->blocksize;
blocklen = (uint64_t)count * (uint64_t)dal->blocksize;
#endif
- if(my_data->disk_car->write(my_data->disk_car,blocklen,buff,my_data->partition->part_offset+off))
+ if(my_data->disk_car->pwrite(my_data->disk_car, buff, blocklen, my_data->partition->part_offset + off) != blocklen)
return 0;
return 1;
}