aboutsummaryrefslogtreecommitdiffstats
path: root/samsung-ipc
diff options
context:
space:
mode:
authorPaul Kocialkowski <contact@paulk.fr>2013-07-03 16:24:14 +0200
committerPaul Kocialkowski <contact@paulk.fr>2013-07-03 16:24:14 +0200
commitd1e05cfad4a5d96885622326ae080b6658ed08a9 (patch)
treebdf5f47a6a54bae66f25b011ae67f057363282ff /samsung-ipc
parent25d384a97f6ffa1b31c5248d1f25df74c686b891 (diff)
downloadhardware_replicant_libsamsung-ipc-d1e05cfad4a5d96885622326ae080b6658ed08a9.tar.gz
hardware_replicant_libsamsung-ipc-d1e05cfad4a5d96885622326ae080b6658ed08a9.tar.bz2
hardware_replicant_libsamsung-ipc-d1e05cfad4a5d96885622326ae080b6658ed08a9.zip
util: Rename block_size to chunk
Change-Id: Icbc6cbe057e9efcc0040540e24e70a967d632ce0 Signed-off-by: Paul Kocialkowski <contact@paulk.fr>
Diffstat (limited to 'samsung-ipc')
-rw-r--r--samsung-ipc/util.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/samsung-ipc/util.c b/samsung-ipc/util.c
index e7bfb01..08c6484 100644
--- a/samsung-ipc/util.c
+++ b/samsung-ipc/util.c
@@ -34,7 +34,7 @@
#include "util.h"
-void *file_data_read(char *path, int size, int block_size)
+void *file_data_read(char *path, int size, int chunk)
{
void *data = NULL;
int fd = -1;
@@ -43,7 +43,7 @@ void *file_data_read(char *path, int size, int block_size)
int count;
int rc;
- if (path == NULL || size <= 0 || block_size <= 0)
+ if (path == NULL || size <= 0 || chunk <= 0)
return NULL;
fd = open(path, O_RDONLY);
@@ -57,7 +57,7 @@ void *file_data_read(char *path, int size, int block_size)
count = 0;
while (count < size) {
- rc = read(fd, p, size - count > block_size ? block_size : size - count);
+ rc = read(fd, p, size - count > chunk ? chunk : size - count);
if (rc < 0)
goto error;