summaryrefslogtreecommitdiffstats
path: root/libhb
diff options
context:
space:
mode:
authorJohn Stebbins <[email protected]>2016-05-24 14:08:24 -0600
committerJohn Stebbins <[email protected]>2016-05-24 14:08:24 -0600
commitcfdd0c22d34c759136336e5e77cd98e9d14001e7 (patch)
treecb39baaddcbf130781e4e83379621c3dc60b14c9 /libhb
parent71ed73bf0f16a428c8540e8b7630ab5a08926958 (diff)
muxcommon: fix check_realloc_output
brainfart!
Diffstat (limited to 'libhb')
-rw-r--r--libhb/muxcommon.c11
1 files changed, 2 insertions, 9 deletions
diff --git a/libhb/muxcommon.c b/libhb/muxcommon.c
index 88a5f35bb..d8f5bbd3d 100644
--- a/libhb/muxcommon.c
+++ b/libhb/muxcommon.c
@@ -727,15 +727,8 @@ static int check_realloc_output(struct output_buf_s * output, int size)
{
uint8_t * tmp;
- if (output->alloc == 0)
- {
- output->alloc = 1024;
- }
- else
- {
- output->alloc *= 2;
- }
- output->size = size;
+ output->alloc = size + 1024;
+ output->size = size;
tmp = realloc(output->buf, output->alloc);
if (tmp == NULL)
{