mirror of
https://github.com/CCExtractor/ccextractor.git
synced 2026-02-14 05:25:44 +00:00
Probably memory leaks #237
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @maxkoryukov on GitHub (Jan 12, 2017).
I think, there are memory leaks here:
6c733e96c9/src/lib_ccx/dvb_subtitle_decoder.c (L1657-1658)memcpyon line 1657 causes overwrites of pointers to the allocated memory:enc_ctx->prev->bufferenc_ctx->prev->sublineenc_ctx->prev->sbs_bufferThis memory is allocated in the function
ccx_encoders_common.c::init_encoder@cfsmp3 commented on GitHub (Jan 12, 2017):
Agreed... we need to have one (or several) clone_contexts functions, such as clone_encoder_context() that creates a copy of allocated memory, etc. With memcpy() we end up with two contexts pointing to the same thing which is going to be a problem, too.
@AlexBratosin2001 this would be yours to look at when possible.
@maxkoryukov commented on GitHub (Jan 13, 2017):
in the mentioned commit (d73b1d11438ec372fb3143edea86926b8cd35f96) I've fixed only the part, related to Sentence Buffer (split to sentences). So, label fix should be replaced with see, because it is just a workaround for SBS and this bug