diff options
author | Mattias Andrée <m@maandree.se> | 2024-10-13 11:17:48 +0200 |
---|---|---|
committer | Mattias Andrée <m@maandree.se> | 2024-10-13 11:17:48 +0200 |
commit | a81c96c0348af8caf6ae45e2d942a676792a2a31 (patch) | |
tree | 24cc725efa3eba381c98ebed7cb2cbf7e0e34f0c /libparsepcf_get_swidths.c | |
parent | Update e-mail (diff) | |
download | libparsepcf-a81c96c0348af8caf6ae45e2d942a676792a2a31.tar.gz libparsepcf-a81c96c0348af8caf6ae45e2d942a676792a2a31.tar.bz2 libparsepcf-a81c96c0348af8caf6ae45e2d942a676792a2a31.tar.xz |
Documentation and minor improvements
Signed-off-by: Mattias Andrée <m@maandree.se>
Diffstat (limited to 'libparsepcf_get_swidths.c')
-rw-r--r-- | libparsepcf_get_swidths.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/libparsepcf_get_swidths.c b/libparsepcf_get_swidths.c index d350b74..f96f14f 100644 --- a/libparsepcf_get_swidths.c +++ b/libparsepcf_get_swidths.c @@ -3,10 +3,11 @@ int -libparsepcf_get_swidths(const char *file, size_t size, +libparsepcf_get_swidths(const void *file, size_t size, const struct libparsepcf_table *table, - int32_t *out, size_t first, size_t count) + int32_t *widths, size_t first, size_t count) { + const char *text = file; int msb = table->format & LIBPARSEPCF_BYTE; size_t pos = table->offset + 8 + 4 * first; size_t i; @@ -14,7 +15,7 @@ libparsepcf_get_swidths(const char *file, size_t size, (void) size; for (i = 0; i < count; i++, pos += 4) - out[i] = PARSE_INT32(&file[pos], msb); + widths[i] = PARSE_INT32(&text[pos], msb); return 0; } |