summaryrefslogtreecommitdiff
path: root/src/index.c
diff options
context:
space:
mode:
authorTimo Teräs <timo.teras@iki.fi>2017-06-21 16:07:58 +0300
committerTimo Teräs <timo.teras@iki.fi>2017-06-23 10:07:44 +0300
commit4d9c0c39b033159f4bd6fe279dd38d4f4a67c904 (patch)
treeb316100ea8a03be653c8cb0c729577c24ebcae14 /src/index.c
parentca9d476ba39d75b9a197f9ae30e5efe2ebafaf3c (diff)
downloadapk-tools-4d9c0c39b033159f4bd6fe279dd38d4f4a67c904.tar.gz
apk-tools-4d9c0c39b033159f4bd6fe279dd38d4f4a67c904.tar.bz2
apk-tools-4d9c0c39b033159f4bd6fe279dd38d4f4a67c904.tar.xz
apk-tools-4d9c0c39b033159f4bd6fe279dd38d4f4a67c904.zip
io: make io vtables const struct, and add accessors for them
This reduces function pointers in heap, and unifies how the io functions are called.
Diffstat (limited to 'src/index.c')
-rw-r--r--src/index.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/index.c b/src/index.c
index 1c39e3c..45d371b 100644
--- a/src/index.c
+++ b/src/index.c
@@ -215,7 +215,7 @@ static int index_main(void *ctx, struct apk_database *db, struct apk_string_arra
fi.name = "APKINDEX";
counter = apk_ostream_counter(&fi.size);
r = apk_db_index_write(db, counter);
- counter->close(counter);
+ apk_ostream_close(counter);
if (r >= 0) {
os = apk_ostream_gzip(os);
@@ -237,7 +237,7 @@ static int index_main(void *ctx, struct apk_database *db, struct apk_string_arra
} else {
r = apk_db_index_write(db, os);
}
- os->close(os);
+ apk_ostream_close(os);
if (r < 0) {
apk_error("Index generation failed: %s", apk_error_str(r));