Skip to content

MemoryLeak fix #3

@brightscorpion

Description

@brightscorpion

Hey, I think this is an awesome project and I love what it does and how beautifully written it is! One small problem I have found in testing is that there is a memory leak. While it can be quite small leak at the rate (30 FPS and 44.1 Hz) that one could be capturing the audio and video frames it can become quite a big leak over time causing to a crash within the apps if videos are long enough. While i am no expert on the matter of memory management as I came in to IOS development after ARC was created it seems that the issues for the leaks is retaining the body object properties in both the FLVVideoTag and the FLVAudioTag objects. I changed
@Property (atomic, retain) NSData *body;
to
@Property (nonatomic) NSData *body;
In both those files. Once the change was in place the memory stayed at around the 10MB mark.

Thanks for your time.
-BrightScorpion

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions