From 86979a2f1baa4777bf17bfba23f44fe20bcf9d72 Mon Sep 17 00:00:00 2001 From: Andre Noll Date: Wed, 11 Aug 2021 21:30:14 +0200 Subject: [PATCH] mp4: Open-code pointless truncate_stream(). This trivial one-liner has only a single caller. --- mp4.c | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/mp4.c b/mp4.c index 9b7d5edb..da904aa8 100644 --- a/mp4.c +++ b/mp4.c @@ -1901,11 +1901,6 @@ static int32_t write_int32(struct mp4 *f, uint32_t data) return write_data(f, temp, sizeof(temp)); } -static int32_t truncate_stream(struct mp4 *f) -{ - return f->stream->truncate(f->stream->user_data); -} - int32_t mp4_meta_update(struct mp4_callback *f, const struct mp4_metadata *data) { void *new_moov_data; @@ -1940,9 +1935,7 @@ int32_t mp4_meta_update(struct mp4_callback *f, const struct mp4_metadata *data) write_data(ff, "moov", 4); write_data(ff, new_moov_data, new_moov_size); } - - truncate_stream(ff); - + f->truncate(f->user_data); mp4_close(ff); return 1; } -- 2.39.5