---
src/simfs.c | 6 ++----
1 files changed, 2 insertions(+), 4 deletions(-)
diff --git a/src/simfs.c b/src/simfs.c
index fd768ef..bcb6ff8 100644
--- a/src/simfs.c
+++ b/src/simfs.c
@@ -231,8 +231,7 @@ static void sim_fs_op_read_block_cb(const struct
ofono_error *error,
tocopy = MIN(256 - op->offset % 256,
op->num_bytes - op->current * 256);
} else {
- bufoff = (op->current - start_block - 1) * 256 +
- op->offset % 256;
+ bufoff = op->current * 256;
dataoff = 0;
tocopy = MIN(256, op->num_bytes - op->current * 256);
}
@@ -294,8 +293,7 @@ static gboolean sim_fs_op_read_block(gpointer user_data)
toread = MIN(256 - op->offset % 256,
op->num_bytes - op->current * 256);
} else {
- bufoff = (op->current - start_block - 1) * 256 +
- op->offset % 256;
+ bufoff = op->current * 256;
seekoff = SIM_CACHE_HEADER_SIZE + op->current * 256;
toread = MIN(256, op->num_bytes - op->current * 256);
}
--
1.7.2.3
_______________________________________________
ofono mailing list
[email protected]
http://lists.ofono.org/listinfo/ofono