]> git.ipfire.org Git - thirdparty/libarchive.git/commit
Do not use private macros for special types
authorPhilippe Daouadi <pdaouadi@aldebaran.com>
Mon, 8 Jun 2015 14:10:02 +0000 (16:10 +0200)
committerPhilippe Daouadi <pdaouadi@aldebaran.com>
Mon, 8 Jun 2015 14:15:12 +0000 (16:15 +0200)
commit72e98eb4ffed327092fbeb8eac7ae37c6093064a
tree1808c192bf0c5c0dc8e03ea09c46ca5fecc471a0
parentaba7cd3e9c4da0be0a60e8ae2249ecc9ac49977c
Do not use private macros for special types

When you need to write a callback for archive_read_open2, you must provide a
function which has the same signature as the typedef. The documentation says
that the read callback returns a ssize_t, but on windows there is no such
ssize_t. libarchive falls back on another type and use the private macro
__LA_SSIZE_T, thus it is not possible to write portable code that use
read_open2.

This patch replaces that macro with a simple typedef la_ssize_t (and does the
same for la_int64_t).
libarchive/archive.h
libarchive/archive_entry.h
libarchive/archive_read.3
libarchive/archive_read_data.3
libarchive/archive_read_open.3
libarchive/archive_write.3
libarchive/archive_write_data.3
libarchive/archive_write_disk.3
libarchive/archive_write_open.3